Hi everyone! I like making lisps so much I've decided to go deeper and try making dcl menus. I found many sites with neat tutorials. I noticed that few use ": text {}"
while others use ": text_part {}" but couldn't find anywhere the difference (if any).
I also made a simple dialog using both simultaneously
[color=red]:[/color] [color=blue]text[/color][color=red]{[/color] [color=blue]label[/color] [color=red]=[/color] [color=magenta]"This is a Test Message"[/color][color=red];[/color] [color=blue]alignment[/color] [color=red]=[/color] [color=blue]centered[/color][color=red];[/color][color=red] }[/color] [color=red]:[/color] [color=blue]text_part[/color][color=red]{[/color] [color=blue]label[/color] [color=red]=[/color] [color=magenta]"This is a Test Message"[/color][color=red];[/color] [color=blue]alignment[/color] [color=red]=[/color] [color=blue]centered[/color][color=red];[/color] [color=red]}[/color]
and the output seemed exactly the same. Is there any difference?
mmm.. so text_part has no leading space and tail.. so using 2 text_part one after another is like having 1 single text.. that's why its named text_part. Logic.
Not very likely, but if someone didn't figure out why with MSasu's example, I'll illustrate with the 2 expressions below, both having the same width of 9 chars.
text_part =>(:text_part{)
text_only =>(:text{)
Since a text has leading/tailing space i'll represent it with " text_only " while i'll represent text_part with "text_part".
With Msasu's example this is why width change and the position shift slightly
" text_only "" text_only "
"text_part"" text_only "
Here are the 4 possibilities with 4 rows:
text_part/text_part
text_part/text
text/text_part
text/text
...all visually looking different even if they contain the same text.
"text_part""text_part"
"text_part"" text_only "
" text_only ""text_part"
" text_only "" text_only "