TinTin++ Mud Client The TinTin++ message board

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
TinTin++ Mud Client

True Colour confusion

 
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> General Discussion
View previous topic :: View next topic  
Author Message
Slysven



Joined: 10 Apr 2011
Posts: 375
Location: As "Jomin al'Bara" in WoTMUD or Wiltshire, UK

PostPosted: Tue Feb 20, 2018 8:01 pm    Post subject: True Colour confusion Reply with quote

I think there is a problem with how you have specified how True Colour is defined with, for instance:
Code:
\033[38;2;rrr;ggg;bbbm

If you refer to the master document for "ANSI" encoding T-REC-T.416-199303-I {a PDF file} and look on page 49 (of 77) - numbered as page 41, you can see that the separator after the 38 should be the (reserved) ':' colon character. This is necessary I think so that a 38 or 48 SGR code be combined with others / each other, remembering of course that any omitted parameter element takes on the value of 0 (zero) so that, say:
Code:
\033[38:2:255;48:2:0:255;9;3m
would be a valid SGR indicating Red foreground on a Green background with crossed-out, italic text. {Though TinTin++ does not support Struck/Crossed out text}...

Importantly, a 38 or a 48 sequence can contain up to 6 values afterwards - although you are probably safe to forget the fourth value as it is only used for the black value for a 38:4 or 48:4 CMYK 36-bit colour value; the fifth value is an integer "tolerance" value and the last is either 0 for the default CIELUV colour space or 1 for the later CIELAB one.


Last edited by Slysven on Tue Feb 20, 2018 9:39 pm; edited 1 time in total
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3844

PostPosted: Tue Feb 20, 2018 9:01 pm    Post subject: Reply with quote

I don't think anyone has seriously looked at the old documentation in a long time.

\e[38;2;rrr;ggg;bbbm is how xterm implemented the option, and a good number of terminals have followed suit.

The WinTin++ terminal supports strikethrough text, but it's probably not supported on most Linux terminals.
Back to top
View user's profile Send private message Send e-mail
Slysven



Joined: 10 Apr 2011
Posts: 375
Location: As "Jomin al'Bara" in WoTMUD or Wiltshire, UK

PostPosted: Sun Mar 04, 2018 8:56 pm    Post subject: Reply with quote

So it is mandatory to get "truecolor" to work on TinTin++ for there to be three more integer numbers between 0 and 255 after the 38 or 48 and then the 2? Normally on SGR sequences zero values can be omitted - though I cannot recall whether that means the corresponding ';' needs to remain or perhaps it, too, can be dropped if there are no following non-zero values?

I am aware that the client I'm coding for currently does the '5' (256-colour) but I've not got around to added the '2'/3'/'4' (24-bit RGB/24-bit CMY/36-bit CMYK) support in...
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3844

PostPosted: Mon Mar 05, 2018 5:53 pm    Post subject: Reply with quote

The current MTTS standard doesn't allow for any exceptions.

http://tintin.sf.net/mtts

http://tintin.sf.net/info/truecolor

Very little information is available, but it's my understanding that 3 integers are mandatory for most terminals.

Are the 38;3 and 38;4 options documented anywhere? First I've heard of it.
Back to top
View user's profile Send private message Send e-mail
Slysven



Joined: 10 Apr 2011
Posts: 375
Location: As "Jomin al'Bara" in WoTMUD or Wiltshire, UK

PostPosted: Fri Mar 09, 2018 9:41 pm    Post subject: Reply with quote

See that PDF link I referred to in an earlier post (and which I added to the Wikipedia ANSI Escape Codes entry as well - Blink)

Scandum wrote:
The current MTTS standard doesn't allow for any exceptions.
Did I delete something that you are referring to - I thought I did say something but I may have edited/reposted and wiped it by accident - for some reason - possibly NoScript/Request policy FireFox add-ons related - the post "Preview" function does not work for me so I have to submit and edit if necessary. Nope

Anyhow, I will raise a couple of questions about that in another topic.
Back to top
View user's profile Send private message
Scandum
Site Admin


Joined: 03 Dec 2004
Posts: 3844

PostPosted: Sat Mar 10, 2018 10:05 pm    Post subject: Reply with quote

Slysven wrote:
Did I delete something that you are referring to

What I mean is that the truecolor definition MTTS links to is pretty strict, and I'm not planning to add any exceptions because I think that would complicate something that so far is pretty straight forward.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> General Discussion All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads
TinTin++ Homepage

Powered by phpBB © 2001, 2002 phpBB Group