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

World: r3wp

[!REBOL3 GUI]

Graham
26-Feb-2010
[914]
A lot more world experience is needed before something unknown is 
added to the GUI
Maxim
26-Feb-2010
[915]
The nice thing about liquid is that its an API more than anything 
and you can model it to do alot of different things, by just changing 
a few properties and implementing one or two functions.


All the nitty gritty is already taken care of and you don't have 
to play around in that unless you really want to create special and 
ultra-optimized nodes whih I very rarely need to do myself.
Graham
26-Feb-2010
[916x2]
Especially something that is hard to understand
Remember that Carl rewrote vid as he found Gab's vid too hard to 
use
Maxim
26-Feb-2010
[918]
yep.
Graham
26-Feb-2010
[919]
Although easy to use as a design aim contradicts his new stance that 
Rebol is not for everyone!
Maxim
26-Feb-2010
[920]
the trick with adding Liquid to R3 VID is to integrate liquid INTO 
VID and not the other way around.  in the VID dialect, or as a few 
function calls which just basically create a predefined node type, 
and links it up.
Steeve
26-Feb-2010
[921]
Graham, i try some idea on my own GUI currently
Graham
26-Feb-2010
[922]
Your own GUI?
Maxim
26-Feb-2010
[923]
in my soon to be released application, the dataflow aspect of the 
code is less than 20% of the time spent, yet it represents at least 
80% of the actual usefull software capabilities.  


most of it was fixing View and VID themselves... the styles, the 
event mechanism and bugs, AGG bugs, enhancing http, etc.
Steeve
26-Feb-2010
[924]
i made some in the past, but they all died before adulthood
Graham
26-Feb-2010
[925]
so genetic defects?
Steeve
26-Feb-2010
[926]
probably ;-)
Graham
26-Feb-2010
[927]
all of these guis and none of them complete ..
Maxim
26-Feb-2010
[928]
an example of a very complex system which was made 100% robust is 
this:

-an image is used as a background, cropped , transformed and displayed 
within AGG

-we need to overlay an text area over the canvas, but its all AGG 
and its contained within a graphic element.

-we create a face which is a text-area, LINK it to the coordinates 
of the graphic element.

-the face is then converted to an image on the fly everytime the 
coordinates change (even rebuilding the text wrapping interactively)

-this image is added at the proper position with the AGG draw block 
as an image with coordinates.
Steeve
26-Feb-2010
[929]
Currenlty, i try a new way.

No VID engine, just an event handler and Gobs as agents talking with 
their environment.
Maxim
26-Feb-2010
[930x2]
focusing on the text area reveals the text-editor face
unfocusing, renders the face as described above.


but because everything is linked, the text-area face even resizes 
& moves automatically when we resize the graphic element without 
needing to unfocus it.
had I tried to build this system without Liquid... 
  -I'd probably have a very brittle textbox.
  -one that is VERY hard to improve.
  -it would lack a lot of the interactive aspects about it.
Steeve
26-Feb-2010
[932]
i decided to throw away any speed constraint to promote dynamic arrangement
Graham
26-Feb-2010
[933]
it's slow?
Steeve
26-Feb-2010
[934x4]
i will be at first
each gob having a lot of methods and properties
each gob having a lot of methods and properties
but then, I will build agents to optimize arrangements dynamicly
Graham
26-Feb-2010
[938x2]
so object oriented gui?
If it's slow .. just get a faster cpu
Steeve
26-Feb-2010
[940]
yep
Maxim
26-Feb-2010
[941]
or use liquid to optimise it.  ;-)
Steeve
26-Feb-2010
[942]
it's what i think now
Maxim
26-Feb-2010
[943x2]
steeve, I think you'd like
.. you'd like my glob engine (only R2 for now).
Steeve
26-Feb-2010
[945]
the opposite principle has been tested with area-tc. Cul de sac.
(i mean, having a fast engine (but huge and hard to maintain)
Graham
26-Feb-2010
[946x2]
The guis that work are object oriented ...
It's just too hard otherwise ...
Maxim
26-Feb-2010
[948x2]
@ jocko on rebol.org there is a working version of liquid and a small 
demo of how it can be merged right into VID called blood.r
it creates relationships between MANY text fields, which become integer 
fields because of the data types of the basic liquid values.
Steeve
26-Feb-2010
[950x2]
and i don't like the need of  a phase to construct graphical objects 
from read-only specs.
All the GUI we had so far, act such.
It's an bad...
bad concept
Maxim
26-Feb-2010
[952]
its why I'm pushing for graphic element as a lower-level api for 
AGG right into view.
Steeve
26-Feb-2010
[953]
to my mind there should not be difference of design between a style 
and a face.

A face is an instantiated style (copied and just showed) , tha't 
enough.
Graham
26-Feb-2010
[954]
at best it only works for very simple layouts
Steeve
26-Feb-2010
[955]
just copy/deep the style :-)
Graham
26-Feb-2010
[956]
so where are you at now?  1% complete ?  :)
Steeve
26-Feb-2010
[957x2]
something like that, i only made tests :(
But it works fine in my brain :)
Graham
26-Feb-2010
[959]
copy/deep Steeve/brain
Maxim
26-Feb-2010
[960]
== ERROR: stack overflow,  reason: brain too deep
Steeve
26-Feb-2010
[961x2]
if only
much like, division by zero
Cyphre
28-Feb-2010
[963]
Maxim, I have hacked together(in fact it was lurking on my hdd for 
couple of weeks but I got to publish it here today) a test of one 
concept which IMO could solve part of your requests regarding 'access 
to DRAW elements' etc in R3. It can be also handy when you need to 
manipulate content of complex DRAW blocks...or even be a base for 
scalable vector graphics editor...or....I think there is relative 
big potential of usage :-)
Just try to run:
do http://www.rebol.cz/~cyphre/scripts/r3/tests/draw-shapes.r
in your R3 console.

BTW The demo also features pixel precise object masking and optimized 
redrawing of DRAW objects just to prove we can do lot of things even 
at the higher level.

The file contains couple of predefined objects but the main code 
is very small like 4kB so it should be easy to see my point. Hope 
this could help a bit to someone.