r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[!RebGUI] A lightweight alternative to VID

Ashley
12-Jun-2005
[1398]
Anton, superb work on the slider/scroller widget. The increased functionality 
more than justfies the increase in code complexity / size. BTW, why 
the support for text? I know why something like "98%" is important 
for progress, but slider/scroller? ;)
shadwolf
12-Jun-2005
[1399x5]
Anton super great work  ;)
Anton can you add an entry to the rebgui on cooking page ?
Anton superb work  !!! Can you put in the on cooking page the entry 
+ the link for this work ?
sorry I get a computer crash and I does see that it was yet posted 
to altme
http://www.rebolfrance.info/articles/regui-cooking-widgs
Anton
12-Jun-2005
[1404]
Thanks guys. I guess I worked hard on it. :)
shadwolf
12-Jun-2005
[1405]
I work on the topic and ashley too so we know and appreciate your 
effort to it's real value ;)
Anton
12-Jun-2005
[1406]
Ashley, text is a bit of an experiment to see where it can go. It 
was easy to add. I wanted to use it in the demo to place some text 
on each slider. It *could* be useful as a hover-over informative 
text (like tooltips) option.
shadwolf
12-Jun-2005
[1407]
Anton I put a modified version to your slider-demo code into my FTP 
and into the On cooking page ;)
Anton
12-Jun-2005
[1408]
Also, I am concerned that making the arrows optional (should be able 
to be dynamically added and removed, by the way) made the code have 
too much voodoo, especially with the draw block.
shadwolf
12-Jun-2005
[1409]
My FTP is a jerk ... it doesn't work
Anton
12-Jun-2005
[1410]
shadwolf, I just reloaded the page, but I do not see the slider..
shadwolf
12-Jun-2005
[1411]
I'm writing it ... and as my ftp is jerked I can't post the adapted 
version of the demo-slider.r file
Anton
12-Jun-2005
[1412]
Ok, so do you want me to do it or do you think you can get around 
the problem ?
shadwolf
12-Jun-2005
[1413x2]
done ;)
some freaking things with my ftp but now it's okay
Anton
12-Jun-2005
[1415]
Ashley, ...and I don't really care about the text that much. Remove 
it if you wish, or just ask me to remove it so my next release is 
consistent.
shadwolf
12-Jun-2005
[1416x2]
I don't get the point ...  people that work on a widget of rebgui 
must be noticed to the public  ;)
this is usefull for us too to know how many people work on a widget 
and what was the role of every intervenent
Anton
12-Jun-2005
[1418]
Yes, I just realised I didn't put much credits in the source. I should 
have credited at least Ashley, because I started from rebgui scroller 
style, listed in rebgui doc as authored by Ashley.
shadwolf
12-Jun-2005
[1419x4]
No problem I make it  ;)
As I say this table about on cooking widgets is like a summary of 
the in progress work ;)
it can be use to collect from public the widgets needs too :)
we all know that the most of the work was done by ashley our intervention 
is most a support one (well in listview it's 100%  my own code ... 
 but that the only one and it's not ended it lot to bet that AShley 
will adapt it befor intergring it to rebgui  :))
Anton
12-Jun-2005
[1423x2]
Just for the record, there is very little original code of the scroller 
in my slider implementation. It is totally re-engineered.
Mmm...  checks don't do face/action when they change state. Is that 
by design ?
Ashley
13-Jun-2005
[1425]
re: check actions - by omission; fixed in next build. I've also updated 
the roadmap to include a link to the RebolFrance Wiki (shadwolf) 
and a link back to the RebGUI Home page (Robert).
Anton
13-Jun-2005
[1426]
ok cool.
Luc
13-Jun-2005
[1427x14]
hello everybody
i'm testing RebGUI for my project
i build my widget for inserting it dynamicly later
i have a problem with the size of an image
that's the code :
; définition du style de l'objet et intégration dans le context de 
RebGUI :
ctx-rebgui/widgets: make ctx-rebgui/widgets [ 
	;; Object' Style definition :
	object: make ctx-rebgui/rebface [
		size: 20x20
		title: ""
		pane: []
		; gestion des évènements :
		feel: ctx-rebgui/widgets/default-feel
		
		; Initialisation :
		init: has [tmp-sze] [
			tmp-sze:  size
			; list countainer
			insert tail pane make ctx-rebgui/rebface compose [
				size: tmp-sze   offset: 0x0 pane: [image img-barre]
			]
			; Insert TitleBar :

   insert tail pane titlebar: make  ctx-rebgui/widgets/image compose 
   [

     image: img-barre size: (as-pair tmp-sze/x 30) offset: 0x0 edge: ctx-rebgui/widgets/default-edge
			] titlebar/init
			; insert scrollers 

   insert tail pane v-scroll: make  ctx-rebgui/widgets/scroller compose 
   [
			 	size: (as-pair 15 tmp-sze/y) offset: (as-pair tmp-sze/x 0)

     ;action: does [scroll-table/y parent-face/pane/1 self] ; put here 
     scrolller function calls
			] v-scroll/init

   insert tail pane h-scroll: make  ctx-rebgui/widgets/scroller compose 
   [
			 	size: (as-pair tmp-sze/x 15) offset: (as-pair 0 tmp-sze/y )

     ;action: does [scroll-table/x parent-face/pane/1 self ]; put here 
     scrolller function calls
			] h-scroll/init
			; insertion  scrollable countainer 
			insert tail pane/1/pane make ctx-rebgui/widgets/box compose [

     size: (as-pair pane/1/size/x (pane/1/size/y - 15))  offset: 0x0 pane: 
     []
 			] 
		]
	]
]
img-barre:
img-barre: load to-binary decompress #{
789CEB0CF073E7E592E2626060E0F5F4700902D266406CCEC104244F54EBE903
29CE028FC8620606AED720CCD8D4CD1B0514644977F4756460D8D857F33B7032
90AF90EC11E4CBC050A5CAC0D0D0CCC0F0F33F907EC9C0506AC0C0F02A8181C1
6A06038378FEA4F8A36E0C0C8C359E2E8E2115B79262F654181E7EC0C6C078E4
88C10B4607868D1B366DE22B52676211E0E6E73FAF50AE0414FAF0E91358E882
00876B0343D2C367CFE49EF8B1702C509C10CBC0D4D13A7366E5046B41858688
1933D8AA2F720838382B8830326570B480F41A1819418C3BFDFFFF7FF69DC220
090B90E27F7F7F9B9F980B54AD53FFFF9F2CC4BC072E0D0C524C82BC40230E74
32309AB014993830F036EEE306928C6007AC60001960A2CC0035A6CDC1851928
5CA00457E1D10DD23807EC8C458C04943981E41A8411CAA210CE00BBE8C25E26
5401836B20D72D8801B39731039DBFBFEEAF14C8F90AD3D6C7EF878613C8A28D
35FFFE4003E6DF9F9FC660BF3A2F78C1C661C0A02EA26B965FF3B31E18670C9E
AE7E2EEB9C129A00CC85951506020000
}
the edge of the image has the correct size but the image hasn't the 
same size than the edge
a sample code to illustrate it
wind: compose/deep [
	button "Ana" [do %anamonitor.r]
	obj: object
	return 
	button "UP" [titlebar/size: titlebar/size + 10x0 show titlebar]
	text (join "REBOL/View :  " system/version)
]
display "Test du style de l'objet LadyBird"  wind
do-events
the edge grows up but not the image
sorry for my english (i'm a french reboler)
and thanks for your help
Ashley
13-Jun-2005
[1441]
With regards to the image size problem, try adding "effect: 'fit" 
to your make image code. Also, it's probably easier to make the image 
directly from a face, as in:

	insert tail pane make ctx-rebgui/rebface [
		offset:	0x0
		size:	as-pair tmp-sze/x 30
		image:	img-barre
		edge:	ctx-rebgui/widgets/default-edge
		effect:	'fit
	]
Anton
14-Jun-2005
[1442x6]
Slider bug has been fixed. It looks solid now.
site: http://www.lexicon.net/antonr/rebol/
load-thru/check site/rebgui/slider.r 1.0.4

do site/rebgui/demo-slider.r  ;<-- modify this file to point to your 
rebgui installation
The fixed bug is the visual off-by-one error and floating-point instability. 
 Text support has been removed from init.
Now, scroller should be able to be implemented in rebgui-widgets.r 
by just:
scroller: make slider [append init [append flags [arrows together]]]
(where 'together is removeable, depending if you want to default 
to amiga-style or not.)