styleClass property case bug

Servoy Developer
Version 3.0b3-build 364
Java version 1.5.0-b64 (Windows XP)
ASA 9.0.2.3207 with a non-case-sensitive database setting.

A number of my posts have been about difficulties getting style classes to work. I may have a clue about why this has been problematic. Consider these syles (I assume that field style will cascade to field.test:

field
{
background-color: #e9e8e8;
border-style: inset;
font: 11pt “Verdana”;
text-align: left;
margin: 1px 2px 1px 1px;
}
field.test
{
text-align: right;
}

Set a field’s styleClass property to test. Check it. The text aligns to the right.

Change the name of the style to tesT. Note the upper-case T. Check it. The text still aligns to the right.

Now change the styleClass property of the field to tesT. Check it.

Note that the text aligns to the left!

Other tests show that no matter what the case of the actual style class identifier in the style sheet, the styleClass property must be all lower case!

Servoy, please acknowledge if you see the same problem. Obviously, in the short term the workaround is: don’t use camelCase in the styleClass property.

Terry

Don’t use camelCase in style names.

Bob,

that’s just what I said!

Does Servoy acknowledge this as a bug?

I know that when we spoke recently about my difficulties in getting style classes to work this was not an issue that you mentioned. So presumably its news to you?

I hope that this note can help save other newbie Servoy programmers from similar frustrations.

Terry

Hi Terry

Some time go I found out and reported on this list the same bug, so I can confirm that behaviour. There are other problems with upper/lower case, e. g. in relationships, attribute names, … and sometimes Servoy logic, where something is made to lower case, e. g. table names.

I also would like very much the Servoy team would correct this, because I think we absolutely should be able to use upper/lower case! After all, it’s supposed to be a Java/JavaScript based development environment.

Best regards, Robert

tkilshaw:
Servoy Developer
Version 3.0b3-build 364
Java version 1.5.0-b64 (Windows XP)
ASA 9.0.2.3207 with a non-case-sensitive database setting.

A number of my posts have been about difficulties getting style classes to work. I may have a clue about why this has been problematic. Consider these syles (I assume that field style will cascade to field.test:

field
{
background-color: #e9e8e8;
border-style: inset;
font: 11pt “Verdana”;
text-align: left;
margin: 1px 2px 1px 1px;
}
field.test
{
text-align: right;
}

Set a field’s styleClass property to test. Check it. The text aligns to the right.

Change the name of the style to tesT. Note the upper-case T. Check it. The text still aligns to the right.

Now change the styleClass property of the field to tesT. Check it.

Note that the text aligns to the left!

Other tests show that no matter what the case of the actual style class identifier in the style sheet, the styleClass property must be all lower case!

Servoy, please acknowledge if you see the same problem. Obviously, in the short term the workaround is: don’t use camelCase in the styleClass property.

Terry

Robert,

do you have any details about other places where Servoy has trouble with mixed case identifiers?

A programmer can spend days pulling their hair out about this kind of problem and wasting lots of time.

Thanks,

Terry

Hi Terry

The ones I mentioned above, which are converted to lower case, i. e. relationship names, attribute names, table names, may others I can’t remember.

Best regards, Robert

tkilshaw:
Robert,

do you have any details about other places where Servoy has trouble with mixed case identifiers?

A programmer can spend days pulling their hair out about this kind of problem and wasting lots of time.

Thanks,

Terry