Re: [Gambas-user] Settings with VSplit control

2010-12-12 Thread richard terry
On Monday 13 December 2010 01:25:10 Phạm Quang Dương wrote: My code is used in probably hundreds of splits all over my program and works 100%. of the time. I'd never ever try and re-size forms or controls using the re-size event - let the properties of the forms/controls do that for you, combin

Re: [Gambas-user] Settings with VSplit control

2010-12-12 Thread Phạm Quang Dương
OK, thank you all. @Terry: your code is like mine. It can not restore VSplit layout. I think problem from Form_Open and Form_Resize. So I did: SUB Form_Open() Dim i as Integer Settings.Read(ME.Window) i = Val(Settings["Group/key"]) vsplit1.Layout = i & "," & (vsplit1.Height - i) END SUB Form_Re

Re: [Gambas-user] Settings with VSplit control -oops

2010-12-12 Thread richard terry
On Sunday 12 December 2010 21:38:49 richard terry wrote: Sorry, didn't delete something as I was cutnpasting and typing: try again: Simple sample code: Public sub Save_Settings() Settings["Your_Section_Name/HSplit_Main.Layout"] = HSplit_Main.Layout end to restore this: Public Sub Set

Re: [Gambas-user] Settings with VSplit control

2010-12-12 Thread richard terry
Simple sample code: Public sub Save_Settings() Settings["Your_Section_Name/HSplit_Main.Layout"] = HSplit_Main.Layout end to restore this: Public Sub Settings_Load() HSplit_Main.Layout = Settings["Your_Section_Name/HSplit_Main.Layout"] = HSplit_Main.Layout End BTW settings is located usu

Re: [Gambas-user] Settings with VSplit control

2010-12-11 Thread Benoît Minisini
> Hi, > > How to save the layout of VSplit? > I tried: > > SUB Form_Open() > vsplit1.settings = Settings["Group/Key"]; > PRINT Settings["Group/Key"] ' (1) > PRINT vsplit1.settings ' (2) > END > > Of course > > SUB Form_Close() > Settings["Group/Key"] = vsplit1.settings > END > > In running, (1