Page 1 of 1

How to stop new field entries from getting auto bolded

Posted: Sat Oct 22, 2016 11:57 am
by Ed_Ray
Does anyone know which field setting stops livecode from automatically "bolding" every new text entry into a field.
I checked all of the field properties including the "text" option which was NOT set to bold.

I had taken care of this before by specifying:
"set the textStyle of word 1 to -1 of field "FieldInUse" to plain" after entering my initial text into a field.

The problem is after I do this initial text entry, I add some styling to the text (some words get italic or bold, some words are colored etc). Some time later I copy the styled text version from my original field to a temp field for LATER retrieval into the original field by means of:
set the htmlText of field "TempField" to the htmlText of field "FieldInUse".

The problem is although all the styling gets copied correctly into the temp field, livecode once again bolds every single word entered into a field. This negates my work because I only want only certain text to be colored and bolded to accent the important text (only the words I took the tedious time of previously styling) with ALL non styled text KEPT plain meaning UNBOLDED.

Why would any livecode developer think bolding EVERY field entry a good default for fields?

Thanks in advance for those that answer.

Re: How to stop new field entries from getting auto bolded

Posted: Sat Oct 22, 2016 3:12 pm
by dunbarx
Hi.

What you are describing is surreal. I have never come across anything like you describe. We do not want haunted software.

What version of LC? What platform?

Are you sure that no handler is changing your textStyle?

Craig Newman

Re: How to stop new field entries from getting auto bolded

Posted: Sat Oct 22, 2016 4:29 pm
by jacque
Text styles in a field use inheritance. If a character in the text itself doesn't have a style assigned it inherits the default text style of the field. It sounds like your temp field is set to be bold by default. Check the text properties of the field.

Re: How to stop new field entries from getting auto bolded

Posted: Sat Oct 22, 2016 6:20 pm
by dunbarx
@Jacque.

Could be, but the OP said he checked the text styles of the field. Hmmm.

@ Ed.

By the way, is this the only field on the card that does this? What does a brand new field do?

And do you see what Jacque meant? If you make a new field in a new stack (just to be sure that nothing is preset) and ask for what seem to be existing properties, like the "textSize", you will get empty. You can type into that field, so how could the textSize be empty?

Craig

Re: How to stop new field entries from getting auto bolded

Posted: Sat Oct 22, 2016 8:08 pm
by jacque
Text inherits from its field, which inherits from the card (I think) which gets it from the stack, which gets it from the home stack which gets it from the system. If the textsize is empty, it's inherited. If you ask for "the effective textsize" you'll get the inherited size.

Re: How to stop new field entries from getting auto bolded

Posted: Sun Oct 23, 2016 4:57 am
by dunbarx
Jacque.

I know that. This is not my first rodeo. 8)

I was speaking to the OP.

Craig :wink:

Re: How to stop new field entries from getting auto bolded

Posted: Sun Oct 23, 2016 5:12 am
by jacque
Sorry Craig, I should have put @Ed on my post too.

Re: How to stop new field entries from getting auto bolded

Posted: Mon Oct 24, 2016 3:46 am
by dunbarx
Jacque.

:D

Always.

Craig

Re: How to stop new field entries from getting auto bolded

Posted: Tue Oct 25, 2016 1:16 am
by Ed_Ray
Hi Craig and other fellow respondents.

I am using livecode ver 8.1. I am using the desktop platform on OS of windows 7 SP1.
And yes I am sure none of my handler's is doing this.

After going through all the fonts one by one I think the issue is that for some strange reason livecode has decided to make the great majority of the fonts dark to very dark to the point that many of them are almost as dark or as dark as a bold text style.

When comparing similar or same fonts in other apps like word for windows, pdf files etc you can really see the marked difference when a font is "bolded" or not but unfortunately this does not apply to livecode where the difference is very hard to see in most cases.

This is problematic because if like in my case, you want make certain line to stand out with color or italics or bold it does NOT help when the surrounding words look almost as dark as the bold ones...its actually quite annoying.

To clarify for some of the other respondents, I did made sure that the default for the fields were not bold and although true that the settings are originally inherited from the stack level, once you pick a different setting at the control level the original inherited setting is overridden by the control level changed setting. This I verified.

While going through all this to respond back to all of your helpful comments, I did notice that if I selected the "(default)" setting for the field font and text was entered into the field, the font was different than if I set it afterwards with a script line such as "set textfont of word 1 to -1 of field id 1003 to "default".

Any reason why this happens?...strange indeed.

Thanks.