Has anyone else had problems with turning on the text formatting for underline in datagrid cells and then not been able to turn it off? Formatting for bold and italic seem to work fine but once the formatting is changed to underline it will not revert back to plain. I can get bold with no underline but I do not want bold. This is in both 7.0.6 and 7.1.0. This may be a bug that I will report if others have seen this too.
Larry
Underline in a datagrid
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Re: Underline in a datagrid
Hi Larry,
sometimes a field "refuses" to stick with its set textfont property.
In that case try this:
...
set the textstyle of char 1 to -1 of fld "xyz" to "plain"
...
At least worth a try!
Best
Klaus
sometimes a field "refuses" to stick with its set textfont property.
In that case try this:
...
set the textstyle of char 1 to -1 of fld "xyz" to "plain"
...
At least worth a try!

Best
Klaus
Re: Underline in a datagrid
Thanks Klaus,
It worked like a charm. Since it was for a datagrid I had to put it into the FillInData script and changed the wording to:
Why is it so common to have to find a workaround while doing something in LIveCode? It is the most frustrating part of working in the language for me.
Regards,
Larry
It worked like a charm. Since it was for a datagrid I had to put it into the FillInData script and changed the wording to:
Code: Select all
set the textstyle of char 1 to -1 of me to "plain"
Regards,
Larry
Re: Underline in a datagrid
Hi Larry,
glad I could help!
Best
Klaus
glad I could help!
This is a rhetorical question, isn't it?lohill wrote:Why is it so common to have to find a workaround while doing something in LIveCode?

Best
Klaus
Re: Underline in a datagrid
One last note: After having set the textstyle to plain in the FillInData script and getting the underlines removed from the dataGrid, I made the assumption that the code could be removed from FillInData. That was not the case however and the next time the grid was filled the underlines reappeared. So the code had to be put back and will forever be a part of that datagrid's overhead.
Larry
Larry