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

World: r3wp

[!RebGUI] A lightweight alternative to VID

Pekr
8-May-2005
[949x4]
I just tried RebGui 022 and would like to report something: Lists 
- once you open selection menu, you can't close it by clicking outside 
of it. ESC works, which is good, but clicking outside the menu should 
close it imo ...
requestors are nice!
What hits my eye a bit though is LED design - too boxy/narrow in 
comparison to check-boxes, radio-buttons etc. The color is a bit 
obtrusive and maybe not all their area needs to be filled with particular 
color? But that is just very cosmetic detail ...
What bothers me more (although with older View 1.2.46 - the memory 
consumption starts growing, even if I do nothing. Anyone noticed 
anything like that?
Vincent
8-May-2005
[953x2]
the event system does that - after a while, some megs, it should 
be garbage collected
A 'recycle was done by RebGUI in earlier versions (patched 'show 
function)
Pekr
8-May-2005
[955]
thanks ...
shadwolf
8-May-2005
[956x8]
the problem of a recycle into show is tha it's performance consumer 
...
maybe we need to talk to carl about this point in order for him to 
make a more efficient way to garbage collect ...
and ofcourse conserving a good process speed :)
maybe it could be preferable to desalocate a content automatically 
when the content change ....
but this is an improvement internal to Core functionnalities ;)
when you do a: 123 then a: "fdsbfsdjbh" it would be interresting 
to detect if the a word yet exist and then trash the interger (123) 
content of this word and then allocate to the word a the string! 
new content.. this will be an internal  totally transparent way to 
handle memory allocation /deallocation
and this will influence every var content (I think that's better 
than having memory leak when event are used ....
new GC is inserted into 102 version but I francly don't see any différence 
in tour.r with RebGUI 0.22  we start a 6800 Ko and the memory is 
cleaned when 8500 Ko is reached and cleaned  to 7400 Ko ...
Vincent
8-May-2005
[964x2]
(regarding de/allocation) I don't know if it would change something 
in our case: in /View, event objects are generated by user/system. 
The event object carrying mouse 'move information may not be used, 
but one can only know and discard it at the end of the event processing 
chain (a global event-func or a face feel) - could be tricky to do
new GC: it must be various corrections to crashes and speedups. I 
don't know if anything has changed on conditions for garbage collection 
triggering.
shadwolf
8-May-2005
[966x3]
I think the memory leak problem with VID  is closely related with 
way data are alocated in general
for example the mouse pointer event is stored into the same var but 
betwin two allocations you have no memory clear so glob vars are 
the same the content is not the same and the only thing that change 
is the memory adress related to the new data allocated
this make increase the memory use until it reach a certain level 
then it's trash maybe it could be bettre to make on new data allocation 
the systematical deallocation of the previous content instead of 
having them surviving into the memory ...
Vincent
8-May-2005
[969x3]
each event is a new object, you can't reuse the same memory place. 
example:
t: copy [] a: insert-event-func [append t event event]
view layout [button "unview" [unview]]
remove-event-func :a
print length? t
foreach e t [probe e/1]
shadwolf
8-May-2005
[972x2]
in this case why the previous obj is not trashed those object have 
a short life time this muts be taked in count I think
In all cases we can solve this by patching the show but this force 
the intensive use a recycle witch was  not designed to do ths ...
Anton
8-May-2005
[974]
Maybe recycle could take an argument, which specifies a word to take 
particular note of.
shadwolf
8-May-2005
[975x4]
yes this would be a first step  ;) instead of scanning comparing 
the whole memory
but the point is that we don't know exactly how recycle works
does it scan the entire memory ? does it make the comparaso betwin 
the whole memory content table and the actual rebol word content 
?
If rebol keeps track of all previous existing data doesn't it simpliest 
to trash those datas when a next allocation is done ?
Ashley
8-May-2005
[979]
Can we move this discussion to the View or Performance group? ;)
shadwolf
8-May-2005
[980]
sure :)
Luisc
9-May-2005
[981x4]
Hi Ashley and Shadwolf  sorry if i didn't answer before i was out 
of town ( mother's day =P ) let me explained to you why the auto-fill 
on a drop-list ...
If you have a big drop-list ( non editable ) with 60 salesman ( big 
store ) and you shadwolf because of your name are close to the 50th. 
position the way to select your name frome that drop list would be 
with the mouse
wouldn't be easier if you typed sh on the drop-list to select your 
name instead ?
and no i am not talking about an edit-list. And is not an auto-fill 
per se routine. More like a keystroke capture routine so that it 
would do a search on the list  = )
Vincent
9-May-2005
[985]
Luisc: usually, drop-lists don't work well with big lists - it's 
quite hard on long lists to select something without mistakely closing 
the list. A classic text-list is far more suited for anything longer 
than 10 elements. A 60 items drop-list will raise a lot of problems: 
if the widget is too low on screen, most of the choices will be hidden.
BrianH
9-May-2005
[986]
Unless your droplist widget adds a scrollbar when there are more 
elements than you specify space in the widget for, like in Windows.
Vincent
9-May-2005
[987]
the combo-box? yes but it's one of the more complicate, buggy and 
error-prone interface in Windows. it's like a popup textlist associated 
with an editable field. (had painful moments with it in Visual Basic)
BrianH
9-May-2005
[988]
I'd have to agree with you if that error-prone complaint is about 
the usability of that kind of control once it's implemented. Still, 
is there a better way of doing what it does? The Mac way perhaps?
Vincent
9-May-2005
[989]
Yes about usability. It's a all-in-one widget: one can use it to 
replace menu, lists, simple requesters (like the fonts and colors 
selection in MSWord), toolbars, auto-complete fields, etc. So it's 
mostly a shortcut to put more widgets (or compact them) in a window 
and can be confusing for users: what will happen if I select something, 
write in the field, click outside the list, click inside on the left, 
on the right, hit enter? It's a full requester in one widget: you 
can do the same with a request-list -like requester with ok/cancel 
buttons.
Luisc
9-May-2005
[990]
Vincent i understand what you are saying and i totally agree with 
you. It is not a big issue all i am trying to convey is that if you 
have a non-editable field with different choices it would be easier 
for some of us  to select those choices with the keyboard instead 
of the mouse.
Graham
9-May-2005
[991]
when you select the language for windows installation, and the timezone 
etc, they use these very large unwieldly drop lists :(
BrianH
9-May-2005
[992]
Oh, I hate that. Even worse, most of the time you can speed up the 
process of selecting from a dropdown by typing the first letter of 
your selection, but all of the time zone selections start with ( 
so that speedup doesn't work with them.
shadwolf
9-May-2005
[993x2]
Luisc we have 2 item in fact edit-list to handle large data with 
some useful stuf like list vertical scroller and auto-fill field 
This is what you want. And the drop -list widget that is for handle 
tinny list of data :)
Luisc so what you need is yet planned and it's called editor-list 
not drop-list ;)
Luisc
9-May-2005
[995]
ah! thank you shadwolf   = )
shadwolf
9-May-2005
[996]
your welcome ;)
shadwolf
12-May-2005
[997x2]
lastest version of my work on Listview widget is available here http://shadwolf.free.fr/rebgui-list49.r
as shown is the example programmer hav only to give to list-viewdata: 
field the new list content then make a show listview to see the chages 
made on the listview.