problem with TextOut()

Discuss any general programming issues here

problem with TextOut()

Postby peceha » Wed Feb 15, 2017 8:06 pm

Hello,

please try following:
Code: Select all
TextOut(#CENTER,#CENTER+10,"          test          ")
TextOut(#CENTER,#CENTER+30,"          test          ",{color=#RED})  ; this line is problematic
TextOut(#CENTER,#CENTER+50,".         test         .",{color=#RED})
WaitKeyDown("any")


looks like there is a problem with second textOut() line - whenever a table with a color is included, the text gets truncated when there are spaces at the end of this text.

Thanks.
peceha
 
Posts: 32
Joined: Tue Dec 13, 2016 9:39 am
Location: Poland

Re: problem with TextOut()

Postby airsoftsoftwair » Sat Feb 18, 2017 7:15 pm

Right, good spot. I'll fix this.
User avatar
airsoftsoftwair
 
Posts: 2000
Joined: Fri Feb 12, 2010 3:33 pm
Location: Germany

Re: problem with TextOut()

Postby airsoftsoftwair » Mon Feb 20, 2017 8:16 pm

Fixed now. As a workaround you can just use

Code: Select all
TextOut(#CENTER,#CENTER+30,"          test          ",{color=#RED, Align = #LEFT})


instead.
User avatar
airsoftsoftwair
 
Posts: 2000
Joined: Fri Feb 12, 2010 3:33 pm
Location: Germany


Return to General programming

Who is online

Users browsing this forum: No registered users and 1 guest