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

World: r3wp

[!RebGUI] A lightweight alternative to VID

Gabriele
15-Mar-2006
[3109]
; default one is very stupid
my-access: make ctx-access/panel [
    set-face*: func [face value /local val][
        if all [block? face/pane block? value][
            either set-word? value/1 [
                foreach [word val] value [
                    set-find-var face/pane to word! word val
                ]
            ] [
                foreach f face/pane [

                    if any [find f/flags 'input find f/flags 'panel] [
                        if not empty? value [
                            set-face f value/1
                            value: next value
                        ]
                    ]
                ]
            ]
        ]
    ]
]
Robert
15-Mar-2006
[3110x3]
How about adding: get-text, get-data? I'm always using those non-existing 
words ;-))
margin: Setting the margin in a bigger layout somewhere in the middle 
"margin 4x4" reset the layout cursor so that the next widget is displayed 
at the "top". Seems that changing MARGIN and SPACING inside a layout 
several times has some problems.
group-box: Today an other idea striked me for group-box. How about 
a way to collapse the group-box like a sub-tree in a tree control? 
With this a GUI could be make very dense and only those parts expanded 
that are currently worked on.

This approach is good for top-down approaches in applications.
Rebolek
15-Mar-2006
[3113]
Robert: I'm using hypernotes for this. There's tree-list on left 
and you can define whatever layout you want with VID tag. I also 
patched hypernotes with SCRIPT tag so I can write code in hypernotes 
and script is generated automatically.
Pekr
15-Mar-2006
[3114]
Robert - something like following? - http://www.xidys.com/winbox.jpg
... it is taken from Winbox app, which we use with our Mikrotik routers 
... dunno what they use as their toolkit,maybe Qt?
Ashley
15-Mar-2006
[3115]
margin/spacing: added to the list.


The drop-down widget panel is actually a standard interface element 
on Mac (forget the name of it) which looks surprisingly similar to 
the JPG Pekr posted. A worthwhile addition I think, although hard 
to implement (as it changes the offset of every widget below it and 
forces a window resize).
Robert
16-Mar-2006
[3116x3]
Petr, yep something like this.
Ashley, shouldn't the span stuff help here? I mean it's somehow like 
a spliter put between the box and the next widget line.
Rebolek, is/could the tree-list be made RebGUI compliant? That would 
be really great!! Especially the idea with the VID tag and the SCRIP 
stuff.
Rebolek
16-Mar-2006
[3119]
Robert: I don't know, I'm not author of HyperNotes, Martin Johannesson 
is. However, he wrote to me, that current version of his list is 
little bit tricky and he's working on new version. So maybe the new 
version may be rewritten for RebGUI. If you like to have a look at 
my patched version of HyperNotes, just let me know.
Gregg
17-Mar-2006
[3120]
The problem I see with the general get-face/set-face approach on 
panels is that values are ordered and unnamed. This makes maintenance 
a problem because, depending on how you deal with that data, you 
have to change things, be aware of the order of fields, etc. It can 
be a nightmare IME. Of course, I want a solution that minimizes my 
code, but I'm even more concerned about keeping it correct.
Robert
17-Mar-2006
[3121]
Gregg, I totally agree. And it's one of those things that drive me 
nuts in VID / View. Sorting faces for z-ordering etc. is really no 
fun. And I have no way to get a reference that's stable.
Gregg
17-Mar-2006
[3122]
My standard approach is to write collect and display routines, which 
isn't so bad if we have a form framework that can do it intelligently, 
or generate the code for us.
Robert
17-Mar-2006
[3123x2]
;-) Issued the request to add this to rebgui.
The nice thing is, that if you create a set of faces that need to 
be collected/restored you don't have to use a zillion of face words. 
You specify them via flags.
Gabriele
17-Mar-2006
[3125]
Gregg: my code above fixes just that, uses name: value instead of 
just block of value.
Ashley
17-Mar-2006
[3126]
The approach I'm looking at will flag widgets (via the options block?) 
with both a reference word and an [optional]  datatype specification. 
You will than have functions like:


 put-values my-display [f1: "Some text" f2: 3-Jan-2005 f5: $20.50]

 put-values/all my-display ["Some text" 3-Jan-2005 3x4 "Fourth field" 
 $20.50]
	get-values my-display [f5 f2]
	get-values/all my-display []


so you can put and get values either by reference, or just do the 
whole lot directly with a /all refinement. The optional datatype 
specification will force a conversion on the returned value. get-values 
will stop at the first failed datatype conversion, instead returning 
the widget reference word.


Still in the planning stage, so other / further suggestions welcome.
Robert
18-Mar-2006
[3127x4]
The interface should be compatible with SQLite, so that no block 
transformation is required. Getting data from SQLite directly to 
the GUI and back.
options block: Yes, good approach.
I expect /ALL only to use ALL widgets that have been flaged.
data-conversion: It would be nice if I can register a call-back function 
that is used.
Ashley
18-Mar-2006
[3131]
Just had an unusual enhancement request from a customer of mine. 
As they fill in fields and areas on a form, they want the ability 
to press Ctrl+B to bold the contents of an entire field / area so 
as they can visually note and review what is important prior to clicking 
"Save" and moving to the next form. It would be fairly easy to add 
this to RebGUI (a Ctrl-B bold toggle), but would anyone else find 
this useful?
Pekr
18-Mar-2006
[3132]
quite non typical ... I wonder ppl don't miss underlined accelerator 
keys, ctrl + tab to toggle between the tabs and clicking away from 
list-down to close :-)
Ashley
19-Mar-2006
[3133]
Because those issues are important to IT folks and totally irrelevant 
to most real world users? ;) Most users don't even know they *can* 
drive a GUI via the keyboard, and if they click on a drop-list they 
*will* pick an item, even it's a blank "no selection" choice (I always 
have the first item of my pick lists as an empty string so users 
can easily click their way out instead of having to press ESC).


  As an aside, what most of my customers were complaining about, until 
  recently fixed, was the fact that drop-lists didn't scale to fit 
  the most items possible ... something no-one here even noticed! ;)
Graham
19-Mar-2006
[3134]
Need request-file/keep .. have to comment out rebgui's request-file 
because it lacks this.  Thanks.
Ashley
19-Mar-2006
[3135]
Issue#47 ... raised by ... Graham. ;)
Pekr
19-Mar-2006
[3136x4]
Ashley - that is simply rudiculous. I have 300+ users at my sight. 
Those type data into system. You really depreciate the fact how ppl 
use computer - the mouse is waste of time, totally ...
well, drop list is not good example of how to use gui via keyboard, 
I do agree :-) our users are not typical users maybe, as they come 
from terminal SAP R2historically, where there was no mouse :-)
my complaint to drop-list is, that it is kind of menu ... and in 
rebol it is driven via show-popup? And that is broken .... I am used 
to close menu by clicking somewhere else .... it happens occassionally, 
when I unintentionally press right mouse button etc., and I really 
don't want any option to be selected ..... so I just move mouse out 
of the menu, and do a left mouse press ... not so with rebol ....
ctrl + tab not even being trapped by rebol view engine is total fiasco 
and I was slammed for that one pretty hard ...
Ashley
19-Mar-2006
[3140]
If the mouse is a waste of time for your users, then they don't need 
a GUI. Just deliver data entry functionality via a console type application. 
My users [medical] make extensive use of TabletPCs so no mouse / 
pen is a bit of a deal-breaker for me. ;)

the mouse is waste of time, totally

 ... so you don't use a mouse for file management (File Explorer) 
 or browsing? And of course you don't need one for Paint type operations? 
 Not everyone who uses a computer is doing pure keyed data entry. 
 Different strokes for different folks.


Anyway, I'm gradually adding keyboard support to RebGUI as time and 
REBOL fixes permit; but it's not high on my list of priorities.
Pekr
19-Mar-2006
[3141x4]
File management? Ah no, you Windows users :-) I would really like 
to see a video, how one can work effectively using such sh*t like 
windows explorer :-) No, I do use Total commander, totally without 
single mouse press ....
and don't try to suggest type of application for my users :-) With 
our past system (now they use SAP R3 and they do complain), they 
used GUI Visual Objects based app - no keyboard, maybe unless they 
wanted something from menu - all forms plus grid were keyboard driven 
- they complained, if some form contained something requiring them 
to touch mouse ....
I am not saying anything - if it works for you, well then. But - 
it does not work for me. I point to the issue of weak keyboard support 
for years. And I know MANY ppl who comlain for rebol not being OS 
friendly. Just go into OS-X group and look what Geomol says about 
proper OS support. I think that ppl are forgiving to a bit different 
look, but not to non-os-compliant behavior ...
and as for browsing - yes, I very often use keyboard - to open new 
tabs (ctrl t), typing search phrase, pressing arrow down (=pointing 
it to google) .... or simply using "find as you type", enter, backspace 
for navigation :-) But that is available in Mozilla/FF
Graham
19-Mar-2006
[3145x2]
We have the Rebgui sources .. we can add support as needed if Ashley 
is too busy, or we can wait for his schedule.
If rebol doesn't support it ... better to hassle Carl instead.
Pekr
19-Mar-2006
[3147x2]
we can't - what you do to switch between tabs, where os uses ctrl 
+ tab, = combination, which rebol does not catch under the hood?
I give up - I hassle them for years, meeting the barriers as Holger, 
or Gabriele, trying to explain me, that universal keyboard cross-platform 
manager is not easy to introduce ... well, I don't care, because 
I don't think, that rebol should support only the lowest common denominator 
of features ... it should play nice with the host os
Graham
19-Mar-2006
[3149x2]
is this relevant to RebGUI ??
If Rebol doesn't support it, then no point mentioning it here ...
Pekr
19-Mar-2006
[3151]
it started with ctrl + B for bold .... so I mentioned I want ctrl 
+ tab, and ability to close menu clicking elsewhere ... at lest the 
second one is in our hands, but rather complicated, if I understand 
the problematics correctly
Robert
25-Mar-2006
[3152x3]
Yesterday I had a phone call with Christian Ensel and we talked about 
how to add more eyecandy to RebGUI. As the RebGUI architecture is 
becoming more and more stable, how about thinking about a simple 
and lightweigth skinning system?
Our idea was to seperate the visual aspects of the widgets into something 
like an own LOOK context. We don't want to made the current widgets 
much more complex. Then RebGUI loads the rebgui-widgets.r and rebgui-look.r 
and you either get Mac, Win or whatevery style you want.
Ashley, do you think this is possible or will it be to complex?
Ashley
25-Mar-2006
[3155]
That's a pretty good approach actually, much like the way locale 
is currently handled. Also fairly easy to implement now that metrics 
/ colors / effects have been centralized. I'll look at adding this 
to the next build.
Pekr
25-Mar-2006
[3156x2]
my vote - go for it ... apart from solid grid/table style, it is 
a bit uniformly (XPish) looking, although latest global changes + 
effects ability helped it ...
guys - but what about solving that event problem - I noticed that 
in VID, you are able to close pop-up menus by clicking elsewhere 
... in Rebgui not .... I thought it is View low level problem, but 
now it seems it is not ...
Ashley
25-Mar-2006
[3158]
0.4.1 is out and is predominantly a maintenance release. From a REBOL/View 
console:

	do http://www.dobeash.com/get-rebgui.r
	do view-root/public/www.dobeash.com/RebGUI/tour.r

Main changes include:

	- set-sizes, set-colors, set-fonts added to global context
	- CTRL-A fires action in text-list / table 'multi mode
	- radio-group, led-group, check-group now auto-size vertically
	- layout now handles false (logic!) correctly

 - effects, sizes and colors can be loaded at startup via like-named 
 dat files (simple skinning system)
	- Minor documentation updates to reflect above changes