It is currently Fri Jul 19, 2019 10:55 am

All times are UTC + 1 hour




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: SetWindowcolor
PostPosted: Mon Apr 09, 2018 5:50 pm 
Offline
Enthusiast
Enthusiast

Joined: Tue Oct 14, 2014 12:09 pm
Posts: 233
Under Linux Ubuntu 17.10 with PB 5.62 X64
Quote:
Setwindowcolor

seems not working
Has someone have had the same problem and how to bypass


Top
 Profile  
Reply with quote  
 Post subject: Re: SetWindowcolor
PostPosted: Mon Apr 09, 2018 6:05 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Sat Dec 03, 2011 5:54 pm
Posts: 736
Location: Oldenburg (Germany)
I can confirm this. With subsystem "gtk2" it works, but not so with default GTK3.

_________________
PB 5.70 LTS (x64) - Debian Testing, Gnome 3.30.2


Top
 Profile  
Reply with quote  
 Post subject: Re: SetWindowcolor
PostPosted: Mon Apr 09, 2018 6:59 pm 
Offline
Enthusiast
Enthusiast

Joined: Tue Oct 14, 2014 12:09 pm
Posts: 233
uwekel wrote:
I can confirm this. With subsystem "gtk2" it works, but not so with default GTK3.

Can you Know how to bypass this problem ? I am new to linuk


Top
 Profile  
Reply with quote  
 Post subject: Re: SetWindowcolor
PostPosted: Tue Apr 10, 2018 4:02 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Sat Dec 03, 2011 5:54 pm
Posts: 736
Location: Oldenburg (Germany)
In the Compiler-Options dialog you have to enter "gtk2" in the Library Subsystem field. The the GTK2 widget set will be used. Hard setting colors in GTK3 is more complex, so i guess Fred has left it out ;-)

_________________
PB 5.70 LTS (x64) - Debian Testing, Gnome 3.30.2


Top
 Profile  
Reply with quote  
 Post subject: Re: SetWindowcolor
PostPosted: Tue Apr 10, 2018 5:02 pm 
Offline
Enthusiast
Enthusiast

Joined: Tue Oct 14, 2014 12:09 pm
Posts: 233
uwekel wrote:
In the Compiler-Options dialog you have to enter "gtk2" in the Library Subsystem field. The the GTK2 widget set will be used. Hard setting colors in GTK3 is more complex, so i guess Fred has left it out ;-)

Many thanks that's works perfectly


Top
 Profile  
Reply with quote  
 Post subject: Re: SetWindowcolor
PostPosted: Tue Feb 19, 2019 2:23 pm 
Offline
New User
New User
User avatar

Joined: Sun Jun 05, 2005 9:45 pm
Posts: 2
You could use a ContainerGadget instead, which wraps around all the other gadgets, and set a backgorund color for it. This works perfectly with GTK3 (which looks much prettier than GTK2). In this case you have to leave the field for the Lbrary Subsystem in the Compiler Options blank. At least this works with PureBasic 5.70 LTS (x64) on Xubuntu.

Code:
OpenWindow(#Window, x, y, InnerWidth, InnerHeight, Title$ [, Flags [, ParentWindowID]])
    Enumeration
        […]
        #cntContainer
    EndEnumeration

    […]

    ContainerGadget(#cntContainer, 0, 0, 432, 504, #PB_Container_Raised)
    SetGadgetColor(#cntContainer, #PB_Gadget_BackColor, RGB(213,255,255))
        [other gadgets]
    CloseGadgetList()

       […]
EndIf ;OpenWindow

_________________
ON ERROR GOTO BED


Top
 Profile  
Reply with quote  
 Post subject: Re: SetWindowcolor
PostPosted: Tue Feb 19, 2019 6:59 pm 
Offline
Addict
Addict
User avatar

Joined: Fri May 12, 2006 6:51 pm
Posts: 1759
Location: Germany
GTK3 Workaround...

Link: viewtopic.php?f=15&t=71992

_________________
My Projects ThreadToGUI / OOP-BaseClass / OOP-BaseClassDispatch / Event-Designer
PB v3.30 / v5.70 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


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