It is currently May 5th, 2024, 4:07 pm

Defined an RGBA in an .inc file, now anything red is black.

Get help with creating, editing & fixing problems with skins
acelaya35
Posts: 3
Joined: March 3rd, 2020, 3:37 am

Defined an RGBA in an .inc file, now anything red is black.

Post by acelaya35 »

I'm new to Rainmeter, i'm putting the finishing touches on my first skin and then all of the sudden the color is all wrong.

I have one color value that's defined as rrr,ggg,bbb,aaa in an .inc file under @Resources but for whatever reason, if I have any value in the red portion, then red is 100% black. It's weird. If I throw in some green like say 50,100,0,255 then I get super dark forest green.

I don't know how I got here and I don't know how to fix it. I hope someone else has been here and knows how to fix it. I've attached the .rmskin, if anyone can take a look I will be forever grateful. :(
You do not have the required permissions to view the files attached to this post.
acelaya35
Posts: 3
Joined: March 3rd, 2020, 3:37 am

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by acelaya35 »

Putting the color values in my .inc file in quotes fixed the issue

:cheers:
mak_kawa
Posts: 908
Joined: December 30th, 2015, 9:47 am

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by mak_kawa »

I think the actual cause is possibly an extra invisible unicode character (x000e) between "=" and "245" of the MainColor variable description in the UTF-16 include file.

Sorry, if it is my misunderstanding.
Last edited by mak_kawa on March 3rd, 2020, 7:16 am, edited 2 times in total.
User avatar
Brian
Developer
Posts: 2689
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by Brian »

I agree with mak_kawa, although it looks like character: 0E 20.
Forum.Invisible.Char.1.png
-Brian
You do not have the required permissions to view the files attached to this post.
mak_kawa
Posts: 908
Joined: December 30th, 2015, 9:47 am

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by mak_kawa »

Hi Brian

I was a bit shifted...one byte. :-) "x0e20" is a Thai character??
User avatar
Brian
Developer
Posts: 2689
Joined: November 24th, 2011, 1:42 am
Location: Utah

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by Brian »

I forgot about endianness. It's 20 0E or the "Left To Right" mark. It's a 0-width character.
http://www.fileformat.info/info/unicode/char/200e/index.htm
https://en.wikipedia.org/wiki/Endianness

-Brian
mak_kawa
Posts: 908
Joined: December 30th, 2015, 9:47 am

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by mak_kawa »

Realm of the Unicode is so deep for me...
User avatar
Yincognito
Rainmeter Sage
Posts: 7199
Joined: February 27th, 2015, 2:38 pm
Location: Terra Yincognita

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by Yincognito »

mak_kawa wrote: March 3rd, 2020, 7:36 am Realm of the Unicode is so deep for me...
Not at all complicated though, at least not for me. And very useful, especially when you are short of ways to manipulate strings to achieve a needed objective.
Profiles: Rainmeter ProfileDeviantArt ProfileSuites: MYiniMeterSkins: Earth
acelaya35
Posts: 3
Joined: March 3rd, 2020, 3:37 am

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by acelaya35 »

Holy crap, I would have never found that. You guys are amazing. Thank you!
mak_kawa
Posts: 908
Joined: December 30th, 2015, 9:47 am

Re: Defined an RGBA in an .inc file, now anything red is black.

Post by mak_kawa »

Hi Yincognito

Yes, you are right. Because it is so deep, it is worth exploring. :-)
But honestly, I am just a noob/hobbyist for Rainmter, so I don't have a skill to enjoy it, yet.

Yesterday I have learned that "Little-endian Unicode character should be read inversely in the binary dump" thanks to Brian. "3D 00 0E 20 32 00" is "003D"(=), "200E"(Left-to-Right) and "0032"(2). It is interesting and useful, at least for me.