TextOut() ignoring text format tags

Feature requests for future versions of Hollywood can be voiced here
Post Reply
djg
Posts: 23
Joined: Wed Feb 12, 2020 10:37 pm

TextOut() ignoring text format tags

Post by djg »

I sometimes have files with weird names that contain characters that TextOut() considers text format tags but are not. I want the file names printed as is so I had to write some code to adapt the file name strings. Although that was easy enough to do, It must always happen and it might not always work correctly. Maybe TextOut() could treat the characters as normal characters when calling it with a #NOFORMATTAGS table element or something?
User avatar
airsoftsoftwair
Posts: 5834
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: TextOut() ignoring text format tags

Post by airsoftsoftwair »

Makes sense. I've added that now.

Code: Select all

- New: Added UseFormatTags() command; this can be used to globally disable text format tags for TextOut(),
  Print() and CreateTextObject(); if you disable text format tags, all text passed to those commands will
  be printed "as is" without applying any formatting; furthermore, TextOut() also supports a "NoFormatTags"
  tag item now that can be used to locally disable text format tags; the "NoFormatTags" tag defaults to
  the global setting configured via UseFormatTags() 
Bugala
Posts: 1390
Joined: Sun Feb 14, 2010 7:11 pm

Re: TextOut() ignoring text format tags

Post by Bugala »

That is a good addition. I was facing this same problem too when I was displaying filenames using TextOut, in some cases these files names might have contained text that would be same as Hollywood TextOut format Tags. While it was easy to fix, main problem is that when a software like that is released, there is no guarantee someone else wouldnt have a file named in such format tag way which I hadnt enocuntered yet, or, if Hollywood would add more format TAGs in the future, then updating the software to the newest Hollywood, might suddenly cause unexpected TAG format behavior, hence this option to disable Tag Format when wanted, is a really good and useful addition.
djg
Posts: 23
Joined: Wed Feb 12, 2020 10:37 pm

Re: TextOut() ignoring text format tags

Post by djg »

airsoftsoftwair wrote: Sun Jun 15, 2025 4:09 pm Makes sense. I've added that now.

Cool! :)
djg
Posts: 23
Joined: Wed Feb 12, 2020 10:37 pm

Re: TextOut() ignoring text format tags

Post by djg »

Bugala wrote: Sun Jun 15, 2025 4:13 pm That is a good addition. I was facing this same problem too when I was displaying filenames using TextOut, in some cases these files names might have contained text that would be same as Hollywood TextOut format Tags. While it was easy to fix, main problem is that when a software like that is released, there is no guarantee someone else wouldnt have a file named in such format tag way which I hadnt enocuntered yet, or, if Hollywood would add more format TAGs in the future, then updating the software to the newest Hollywood, might suddenly cause unexpected TAG format behavior, hence this option to disable Tag Format when wanted, is a really good and useful addition.
Well said. Glad you agree.
Post Reply