It is currently Sun Jul 22, 2018 9:21 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 525 posts ]  Go to page Previous  1 ... 30, 31, 32, 33, 34, 35  Next
Author Message
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Wed Jun 23, 2010 10:38 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Fri Apr 04, 2008 6:20 pm
Posts: 135
Location: Belgium
You are right when you say :
Quote:
I am not recommending not to use PureCOLOR (I use it myself), but to use PB genuine functions whenever it's possible. Etc...

And I think it's also true with all genuine functions... wherever possible and it exists ! :lol:

_________________
Sorry for my english :wink: ! (Windows Xp, Vista and Windows 7, Windows 10)


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Thu Jun 24, 2010 7:36 am 
Offline
PureBasic Expert
PureBasic Expert
User avatar

Joined: Sat Apr 26, 2003 8:27 am
Posts: 4229
Location: Strasbourg / France
SoS wrote:
Hi gnozal
PureColor is not working in threadsafe mode.(winxp 32)
I get "unresolved external.... _PB_Stringbase".
Did you enable the 'UserLibThreadSafe' subsystem (see PureCOLOR.chm) ?

_________________
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Fri Jun 25, 2010 6:50 pm 
Offline
User
User

Joined: Tue Feb 23, 2010 8:39 pm
Posts: 62
Location: Canada
gnozal wrote:
nigel wrote:
I am still interested in understanding your reasons for recommending against the use of Purecolor. Is it just because it involves an external library and because you think the Purebasic author may eventually improve colour support natively within the language itself ?
I am not recommending not to use PureCOLOR (I use it myself), but to use PB genuine functions whenever it's possible.
Several reasons :
- PureCOLOR does not support themes (it could have better support for themes, but it would be a lot of work and I am not using themes anyway, so...)
- some PB gadgets are not 100% Windows API compatible, so using an external library for coloring may have some unexpected results : the listicon grid lines issue, the combobox coloring not working when #PB_ComboBox_Image is used, ....
I don't think the PB authors will improve color support a lot because most users use themes, and they have 3 OS to support. But I may be wrong.

PureFORM uses PureCOLOR internally because it's an old app written with PB3.9x which had absolutely no color support at the time, nor icon menus.
However, in the generated code, you can choose between PureCOLOR and the genuine SetGadgetColor() function, and this for every class. It may not be supported by PB though.


gnozal

Inadvertantly, your answer has pointed me in the direction of resolving my problems.

This might sound rather astonishing, but as I am new to Purebasic and also to Windows GUI programming, I was not aware that theme choices determine the colour scheme used by a developed application. Like you, I do not use themes because I have no desire to use a background desktop wallpaper and prefer a plain unadorned working environment. I suppose you might say that I do use a theme in the sense that I choose "Classic" which includes a plain blue desktop background. My choice of "classic" results in a very unappealing grey coloured background to any developed application, whereas using the Windows XP theme generates a pleasant sandy beige application backdrop.

I had certainly assumed that every author of an application needed to program the colours for each interface element. This is a basic misunderstanding on my part and I am now happy to generally avoid specifying colour in Purebasic altogether.

Thanks again gnozal, I also appreciate the additional insights your answer has provided.


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : Frame3DGadget Text
PostPosted: Thu Jul 01, 2010 7:50 pm 
Offline
New User
New User

Joined: Fri Nov 13, 2009 10:33 pm
Posts: 7
Goznal,

Would it be possible to add custom coloring to the Frame3DGadgets into the PureColor Library?

See this thread for details:
viewtopic.php?f=12&t=42743

Thanks for the excellent work, as coloring check box's and option boxes without your efforts would be a Hugh Pain.

Rnospam


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Thu Jan 20, 2011 11:38 am 
Offline
PureBasic Expert
PureBasic Expert
User avatar

Joined: Sat Apr 26, 2003 8:27 am
Posts: 4229
Location: Strasbourg / France
Update (V16.0 for PB4.5x)

Changes :
- new function : PureCOLOR_DisableButton(GadgetNumber.l, Disabled.l)
  To be used instead of the PB genuine function DisableGadget() for colored and/or icon buttons.
  Should provide a better cosmetic result for disabled buttons.

Example : enabled buttons
               disabled buttons

_________________
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Sun May 08, 2011 5:16 am 
Offline
Always Here
Always Here

Joined: Fri Oct 23, 2009 2:33 am
Posts: 5774
Location: Wales, UK
Hello gnozal

This is the first time I have really needed to colour gadgets. Really impressed with PureCOLOR, it's very easy to use and fast! 8)

Did you notice that applying colour to individual ListIcon cells results in the grid lines disappearing? Is there a way to get them to stay?

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Tue May 17, 2011 8:21 am 
Offline
PureBasic Expert
PureBasic Expert
User avatar

Joined: Sat Apr 26, 2003 8:27 am
Posts: 4229
Location: Strasbourg / France
IdeasVacuum wrote:
This is the first time I have really needed to colour gadgets. Really impressed with PureCOLOR, it's very easy to use and fast! 8)
Did you notice that applying colour to individual ListIcon cells results in the grid lines disappearing? Is there a way to get them to stay?
Yes.
PureCOLOR.chm wrote:
If the grid lines disappear, use this workaround : SendMessage_(GadgetID(#MyListIcon), #LVM_SETEXTENDEDLISTVIEWSTYLE, #LVS_EX_GRIDLINES, #LVS_EX_GRIDLINES)

_________________
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Tue May 24, 2011 4:22 am 
Offline
Always Here
Always Here

Joined: Fri Oct 23, 2009 2:33 am
Posts: 5774
Location: Wales, UK
Thanks for your reply gnozal. Somehow did not see the work-around in the help, sorry to trouble you. :oops:

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Tue May 24, 2011 7:49 am 
Offline
PureBasic Expert
PureBasic Expert
User avatar

Joined: Sat Apr 26, 2003 8:27 am
Posts: 4229
Location: Strasbourg / France
IdeasVacuum wrote:
Thanks for your reply gnozal. Somehow did not see the work-around in the help, sorry to trouble you. :oops:
No problem, you're welcome.

_________________
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Sun Jul 10, 2011 5:57 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Thu Apr 07, 2011 1:14 pm
Posts: 243
Location: 3 arks
Hi

Is there a new version of the purecolor lib ?
For pb4.60 ? :)

Thank you very much.


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Sun Jul 10, 2011 6:59 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Sat May 05, 2007 5:31 pm
Posts: 462
Location: Linz, Austria
Yup, PureCOLOR for pb4.6 is online... Just download the 'Tools Updater' from gnozal´s hp ( http://gnozal.ucoz.com/#Tools ) and check for news from time to time.


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Tue Jul 19, 2011 9:49 am 
Offline
Addict
Addict
User avatar

Joined: Wed Apr 30, 2003 8:15 am
Posts: 954
Location: Germany
PureCOLOR_SetButtonColor(0, #White, #Black) PB4.6B3 crashes, if the ButtonImageGadget ()
is disabled.

Code:
  If OpenWindow(0, 0, 0, 120, 100, "ButtonImage", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
    If LoadImage(0, #PB_Compiler_Home +  "Examples\Sources\Data\PureBasic.bmp")    ; change 2nd parameter to the path/filename of your image
      ButtonImageGadget(0, 10, 10, 100, 83, ImageID(0))
         
      EndIf
   
      DisableGadget(0, #TRUE)
      
      PureCOLOR_SetButtonColor(0, #White, #Black)
      
      Repeat
      Until WaitWindowEvent() = #PB_Event_CloseWindow
   EndIf

_________________
"Daddy, I'll run faster, then it is not so far..."


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Tue Jul 19, 2011 10:56 am 
Offline
PureBasic Expert
PureBasic Expert
User avatar

Joined: Sat Apr 26, 2003 8:27 am
Posts: 4229
Location: Strasbourg / France
dige wrote:
PureCOLOR_SetButtonColor(0, #White, #Black) PB4.6B3 crashes, if the ButtonImageGadget ()
is disabled.

New build uploaded (should not crash anymore).

_________________
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).


Top
 Profile  
Reply with quote  
 Post subject: Re: PureCOLOR library : coloring gadgets (and much more)
PostPosted: Tue Jul 19, 2011 11:11 am 
Offline
Addict
Addict
User avatar

Joined: Wed Apr 30, 2003 8:15 am
Posts: 954
Location: Germany
Thank you! It works... :D

_________________
"Daddy, I'll run faster, then it is not so far..."


Top
 Profile  
Reply with quote  
 Post subject: PureForm,PureColor = goofy text?
PostPosted: Sat Oct 15, 2011 7:13 pm 
Offline
Addict
Addict
User avatar

Joined: Wed Feb 17, 2010 12:00 am
Posts: 1239
Location: Anderson Island, WA
Image
Notice the "blurry" text? It gets blurry as soon as the colour of the object beneath changes.
How can I avoid it?
Thanks.
Here's the code:
Code:
    
pWindow = OpenWindow(#PB_Any,0,0,10,10,"",#PB_Window_Invisible)
hWindow = OpenWindow(#PB_Any, 450, 200, 352, 62, "Having Fun", #PB_Window_Invisible|#PB_Window_SystemMenu,WindowID(pWindow))

hprog1 = ProgressBarGadget(#PB_Any, 6, 1, 340, 25, 0, 100, #PB_ProgressBar_Smooth)
hText1 = TextGadget(#PB_Any, 7, 3, 340, 20, "0%", #PB_Text_Center|#SS_CENTERIMAGE)

hProg2 = ProgressBarGadget(#PB_Any, 6, 31, 340, 25, 0, 100, #PB_ProgressBar_Smooth)
hText2 = TextGadget(#PB_Any, 5, 34, 340, 20, "0%", #PB_Text_Center|#SS_CENTERIMAGE)


SetGadgetFont(hText1, LoadFont(#Font_txt2, "Microsoft Sans Serif", 8, #PB_Font_Bold|#PB_Font_HighQuality))
SetGadgetFont(hText2, LoadFont(#Font_txt3, "Microsoft Sans Serif", 8, #PB_Font_Bold|#PB_Font_HighQuality))

PureCOLOR_SetGadgetColor(hText1, $FFFFFF, #PureCOLOR_DontSetBackColor)
PureCOLOR_SetGadgetColor(hText2, $FFFFFF, #PureCOLOR_DontSetBackColor)


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 525 posts ]  Go to page Previous  1 ... 30, 31, 32, 33, 34, 35  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 2 guests


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

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye