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

World: r3wp

[!RebGUI] A lightweight alternative to VID

Volker
5-Dec-2005
[2595]
The license was gpl-compatible, so that it runs with beer?
Ashley
5-Dec-2005
[2596]
Better than GPL:


RebGUI is a community project that is free for both commercial and 
non-commercial use. Dobeash Investments Pty Ltd retains copyright 
on the name RebGUI and the concepts embodied in the display function 
as well as all associated documentation other than that which covers 
REBOL/View Facets.

Code submissions, in particular widgets, will 
be accepted and credited to the author under the condition that they 
carry these same licence conditions.
Volker
5-Dec-2005
[2597]
SOunds like i can "link" with gpl.
Ashley
5-Dec-2005
[2598x2]
Yes, no problems. You can also change and modify without any requirement 
to contribute back. Also, there is no requirement for attributions 
/ acknowledgements.
With regards to actions, I was contemplating adding pre and post 
action triggers that were fired on focus and unfocus respectively. 
I think the existing action / alt-action / dbl-action triggers cover 
the widget-action class sufficiently. Comments?
Volker
5-Dec-2005
[2600x2]
Would enable better editors. saving caret in face itself, for later 
find, replace etc.
WOuld like a textface which does that automatically.
shadwolf
5-Dec-2005
[2602x2]
edges problems hihihih this kind of bug i absolutly don't have on 
my computer and  i don't know why ...
i will merge it  ...
Graham
5-Dec-2005
[2604]
Ashley, how would you decide whether you only wanted the unfocus 
trigger?
Ashley
5-Dec-2005
[2605]
focus would look for a face/focus function while unfocus would look 
for a face/unfocus function. So the code might look like:

	...
	field unfocus-action [do-validation face/text]


the validation, if it failed, might shift focus back into the field 
the user tried to leave. Something like that I guess.
Graham
5-Dec-2005
[2606x2]
Would there be a way so that the default action is triggered by an 
unfocus event ?
Rather than having to specify 'unfocus-action ...
shadwolf
5-Dec-2005
[2608x9]
okay i see the edge bug now when i merge the listview code in the 
regui-wiget.r file ^^
it's seems like i have to insert edge: default-edge in all my dyn 
rebfaces ....
rebface is supose to yet include it and be an empty box lol
how i understand this bug ashley RebGUI widget compositor expect 
to find a edge field in this object and as it doesn't it crash
i'm adding edge:	default-edge on all rebfaces this  doesn't work 
neither  ...
odd problem i don't see a solution ...
maybe that have somthing to do with the way  widget is updated
i use event show to restart the rendering and display then the changed 
content  (colum-countainer ) this all auto table rebuild when script 
simply call show listview-widget
ffrom his application code
Ashley
5-Dec-2005
[2617]
Given that it worked stand-alone, my guess is that one of the make's 
was referring to "something" in the global context (face, feel, pane, 
etc) which enabled it to work. Regardless, it's a very obscure error.
shadwolf
6-Dec-2005
[2618]
in this case the  error would be i can find this world or something 
like that...
Robert
6-Dec-2005
[2619x3]
events: IMO a very, very important thing to add to RebGUI. Think 
about your apps. I always need this feature and most frameworks etc. 
don't support it well. The problem is, that if you have to add it 
yourself, the code becomes hughe and complicated for maintenance.

Adding a focus / unfocus action sounds like a good way to do it.
A way to set default focus / unfocus action would help keeping the 
code clean. With this I could change the default action on the fly 
and all new widgets would than use the new version. Makes building 
up forms a lot simpler.
Anyway, so how to solve my problem at the moment? I'm stucked without 
a solution to this.
Graham
6-Dec-2005
[2622]
I suspect that Ashley will release once he has tested against the 
new sdk
Ashley
6-Dec-2005
[2623]
While I'm waiting on listview52 I'll see if I can slip some prototype 
focus / unfous trigger code and bubble-menu in for you Robert. ;)
Graham
6-Dec-2005
[2624]
After reverse, pad pads to the right and not the left as expected 
...( by me that is ! )
Ashley
6-Dec-2005
[2625]
How's this for focus / unfocus trigger logic?

1. Add two user-definable action handlers to ctx-rebgui

	app-focus-action: func [face] [true]
	app-unfocus-action: func [face] [true]

2.Modify the ctx-rebgui/edit focus and unfocus functions:

	unfocus: has [face][
		if face: view*/focal-face [
			unless face/unfocus-action face [return false]
		] 
	...

	focus: func [
		"Focuses key events on a specific face."
		face [object!]
	][
		unless unfocus [return]
		if face/show? [
			unless face/focus-action face [return false]
	...

3. Extend the standard rebface definition

4. Add the following to the layout function:


 focus-action: either attribute-focus-action [make function! [face 
 /local var] attribute-focus-action] [:app-focus-action]

 unfocus-action: either attribute-unfocus-action [make function! [face 
 /local var] attribute-unfocus-action] [:app-unfocus-action]

which would then let us write code like:


 ctx-rebgui/app-focus-action: func [face] [face/text: form random 
 1000]

	display "" [
		field
		field focus [face/text: form now/time/precise]
		field
	]


The logic is simple: "Execute the default focus / unfocus functions 
(which in turn default to true) *unless* a focus / unfocus function 
has been provided for the face. When a focus / unfocus event is called 
execute the assigned handler function *first* and only proceed if 
it returns true."

Does this meet the design requirement?
Chris
7-Dec-2005
[2626]
ctx-rebgui/app-focus-action: func [face] [face/text: form random 
1000]
; would this line change every face that receives focus?
Ashley
7-Dec-2005
[2627]
Yes ... unless overridden by a local definition (e.g. field focus 
[true]])
Brett
7-Dec-2005
[2628]
Hi. Just looking through rebgui. A question and a comment. (1) In 
the readme.txt file there is a reference to Opera icons but no reference 
to the licensing of those icons. Where can I find the icon licensing 
information please?

(2) I like the table widget with it's sortable columns. But at first 
had problems with trying to sort in the reverse direction because 
I was targetting the sort indicator triangle which does not do anything.
Graham
7-Dec-2005
[2629]
the latter point has been noted in the problems list
Ashley
7-Dec-2005
[2630x2]
1) These are provided as samples only (for %tour.r) and given that 
I could not find any reference to the licensing of them I added that 
note instead. If anyone has a source of good, free program icons 
then let me know and I'll get rid of the Opera ones.

2) Issue#44 at http://www.dobeash.com/it/rebgui/issues.html
Latest build available at: http://www.dobeash.com/files/RebGUI-038.zip

Issue log: http://www.dobeash.com/it/rebgui/issues.html


*** Unzip this file into your existing RebGUI 0.3.0 distribution. 
Requires View 1.3.1 (1.3.2 preferred) ***


This is mainly a bug-fix release with a new prototype event trigger 
system (see %"Demo - actions.r") and a very early proof of concept 
bubble-menu (see %"Demo - bubble-menu.r").


I'm particularly keen to see whether the event trigger system is 
flexible enough to remove [or reduce] the need for a dedicated (and 
hard to design / implement) one-size-fits-all "field validation" 
system as discussed previously. The bubble-menu demo shows how transparency 
and event detection within a non-square area *could* be done. The 
implementation is not perfect (or anywhere near usable) so I'm open 
to alternate design suggestions! ;)
Anton
7-Dec-2005
[2632x5]
The close event of DISPLAY's default view-face/feel/detect assumes, 
after   face/alt-action face   has been done, that there is still 
a face in system/view/screen-face/pane.

This is a problem when I wanted the window close button to return 
me to the console, like so:
display/close "" [box 10x10][unview] do-events
** Script Error: Out of range or past end
** Where: switch
** Near: if face = first system/view/screen-face/pane
(Perhaps I am going about that the wrong way ?)
Anyway, I might advise to replace FIRST with PICK.
eg.  it becomes:    if face = pick system/view/screen-face/pane 1
shadwolf
7-Dec-2005
[2637]
congratulation ashley very funnew  things ^^
Pekr
7-Dec-2005
[2638]
- still - pop-up system non system friendly (not Rebgui issue, but 
rebol one's)

- I have some difficulcy with leds - If you would not provide me 
with text help, I would very hardly know, what those state means 
- I am not sure such style has place in standard pack ... or just 
- let it transparent for 'not-selected selection, green for 'on selection, 
red for 'off selection ...

- table - still you are able to scroll hilited row "under" the table 
style border - it should know it is at last displayed element and 
start scrolling, scrollers should reflect that. If there is no internal 
track of hilited row/cell, then it is not true grid system (I hope 
not)

- bug with text-list multi selection - there seem to be bug in math 
... press shift, hold it, hilite e.g. 6 rows. Still hold it, press 
some two rows below, it let's hilited only first two rows ...
Graham
7-Dec-2005
[2639]
Ashley, there's still a problem with area fields.  If you start typing 
in the area field in tour.r at the top of the field, when you reach 
the end of the line, and the word wraps, the cursor drops to the 
end of the area field taking you away from the line you are typing.
Volker
7-Dec-2005
[2640]
Once try to fix that: http://polly.rebol.it/test/test/rebgui/.
Pekr
7-Dec-2005
[2641]
and demo for field validation does not work at all ...
Graham
7-Dec-2005
[2642x2]
ie. Issue 48 is still open.
what do you mean "at all" ?
Pekr
7-Dec-2005
[2644]
too many bugs at first try to bother to test it further ...