ColorRequester everything ok

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
User avatar
Hyper
User
User
Posts: 11
Joined: Sat May 23, 2009 10:40 am

ColorRequester everything ok

Post by Hyper »

Hello,

as written in the title, is not possible to define and apply a custom color. Can be tested with the code from the help:
[code]
Farbe.l = ColorRequester()
If Farbe > -1
a$ = "Sie haben folgende Farbwerte ausgewählt:" + Chr(10) ; Chr(10) wird nur
a$ + "24 Bit Wert: " + Str(Farbe) + Chr(10) ; für den Zeilen-
a$ + "Rot-Wert: " + Str(Red(Farbe)) + Chr(10) ; umbruch benötigt
a$ + "Grün-Wert: " + Str(Green(Farbe)) + Chr(10)
a$ + "Blau-Wert: " + Str(Blue(Farbe))
Else
a$ = "Der Requester wurde abgebrochen."
EndIf
MessageRequester("Information", a$, 0)
End
[/code]

Greetings
Hyper
Last edited by Hyper on Tue Nov 03, 2009 4:38 pm, edited 1 time in total.
freak
PureBasic Team
PureBasic Team
Posts: 5940
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Re: ColorRequester: define custom colors doesn't work

Post by freak »

That is not a bug. If anything, its a feature request.
quidquid Latine dictum sit altum videtur
rsts
Addict
Addict
Posts: 2736
Joined: Wed Aug 24, 2005 8:39 am
Location: Southwest OH - USA

Re: ColorRequester: define custom colors doesn't work

Post by rsts »

Work as as it says.

Try Color.l = ColorRequester(#red)

Don't be quite so hasty to report a "bug" :)

cheers
User avatar
Hyper
User
User
Posts: 11
Joined: Sat May 23, 2009 10:40 am

Re: ColorRequester: define custom colors doesn't work

Post by Hyper »

Really you are right:
I chose a color from the right custom-color-field with the cursor and pushed the button “add color”. But, the box on left side doesn’t change. Why? The vertical track bar stayed at the lowest position, so each color you choose from the field will be initially black. And if you add the color, you see no modification. Now I know that I have to move the vertical track bar to adjust the brightness at first and then add the color.

Confirmed: It’s not a PureBasic bug.

Sorry for the annoyance
Hyper

PS: I modified the titel of the post.
Post Reply