GTK3 - Disabled SpinGadget() with Flag #PB_Spin_ReadOnly

Linux specific forum
Oma
Enthusiast
Enthusiast
Posts: 312
Joined: Thu Jun 26, 2014 9:17 am
Location: Germany

GTK3 - Disabled SpinGadget() with Flag #PB_Spin_ReadOnly

Post by Oma »

Hi again,

in PB5.40B1-3 a SpinGadget(#Gadget, x, y, Breite, Höhe, Minimum, Maximum [, Flags]) with set Flag #PB_Spin_ReadOnly is completely deactivated instead of the editability of the entry ...

Code: Select all

#Win_Main  = 0
#SpG1      = 0
#SpG2      = 1

Global.i gEvent

Procedure Create_WinMain()
	If OpenWindow(#Win_Main, 300, 200, 250, 200, "Window", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
		SpinGadget(#SpG1, 5,  5, 100, 30, 10, 20, #PB_Spin_Numeric); works
		SpinGadget(#SpG2, 5, 40, 100, 30,  0, 10, #PB_Spin_Numeric | #PB_Spin_ReadOnly); should disable only the entry, not the whole gadget

	EndIf
EndProcedure

Create_WinMain()

Repeat
	gEvent= WaitWindowEvent()
	gEventWin= EventWindow()
	
	If gEventWin = #Win_Main
		Select gEvent
			Case #PB_Event_CloseWindow
				gQuit= #True
		EndSelect
	EndIf
Until gQuit
Regards, Charly
PureBasic 5.4-5.7, Linux: (X/L/K)Ubuntus+Mint - Windows XP (32Bit)
PureBasic Linux-API-Library & Viewer: http://www.chabba.de
Fred
Administrator
Administrator
Posts: 18350
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB5.40B1-3 Disabled SpinGadget() with Flag #PB_Spin_Read

Post by Fred »

Seems like GtkSpinButton doesn't support this with GTK3, so for now it will do nothing on Linux (doc updated).

https://developer.gnome.org/gtk3/stable ... utton.html
Post Reply