• Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

World: r4wp

[#Red] Red language group

My understanding is that most people stick to one desktop OS, they 
are not switching OSes whole day (that is just a very small minority 
of computer users). Having close integration with OS can bring many 
advantages over a custom GUI like hardware acceleration or close 
integration with OS/desktop services. There are still cases where 
a custom cross-platform GUI could be good enough, so a View-like 
engine for Red is welcome. I just think that the default GUI option 
should be to provide an OS-integrated user experience.
Ah, I thought so, could count minutes before someone comes with "hardware 
acceleration claim". We havent ever utilised full speed of new View 
engine in R3, yet we want it even faster :-) But understood, some 
mobile devices might not have FPU or so ...
So on Android, it looks like andorid, etc., but also - for small 
embedded - either html5, or View ...

That sounds like what Doc is proposing.
I found it to be slow
Doc - I used some programming languages on Windows - Visual Objects, 
Delphi ... button here, button there, button with bitmap. Wait - 
CA-VO did not have such a class - almost impossible to obtain such 
a feature. Then I show few small demos of View2 from the desktops, 
and those big guys come like - huh, how is that so easily possible?
Petr, don't lose focus. The train is going in your direction. Just 
get out of the way. :-)
So - just please show me a bubbless demo written using GTK. Do you 
have a widted for that? And that's my point.
I want ALSO View/VID, which is being kind of dismissed here both 
by Doc and Kaj :-)

 Absolutly not, I'm just saying that I will build a native GUI solution 
 first, a View-like solution is not my priority but it is welcome. 
 If nobody makes a View-like engine, nor wraps R3/GUI engine, I will 
 consider making one myself when I will have more time.
I've already said that I will make one, but Petr keeps maintaining 
the reverse
Petr, do you see that we're all in very close agreement here?
We havent ever utilised full speed of new View engine in R3, yet 
we want it even faster :-)

What I just say is that you have it for free when using native widgets.
OK, I need to work 32 hours a day to contract Cyphre, to make it 
a bit higher priority :-)
Great. We'll all appreciate that. And you see, now, that we all agree?
Doc - I know - what I want is - free form GUI, not necessarily a 
native GUI, which is mostly good for forms like apps imo. Or just 
please show me particles.r 1.6KB demo rewritten to GTK :-)
That's no problem if I bind the canvas widget, but I'd rather do 
it in Enlightenment
Is this helping at all Doc? I'd like to say this has run its course 
right now, and we should let Doc focus, and others can comment later.
Gregg - I will see how Red evolves in regards to events etc., so 
that later on I can have someone look, how difficult would it be 
to port View from R3 to Red/System. AGG is just platform agnostic 
(I think), then there's a windowing system, maybe not so difficult, 
but Doc might have some other plans for events, etc.
Gregg - Doc is focused, don't worry. He is used to my folklore. I 
know where he might be heading (in a bigger picture, not details)
He might, but let's not dive into that right now. Do you see that 
we agree, and we know what you want in a GUI? And if you want us 
to remember it, you can put it in a file or checklist here. Please. 
I created a folder and blank file for you Petr: %Red/GUI/Petr's Wishlist.txt
Thanks Gregg.
Added FUNCTION constructor, works like FUNCT in R3.
Gregg - no need to make me look dumb. My wishlist.txt is just one 
line - get the small cross-plaftorm View like engine for Red available 
too - it might be attractive to many ppl, easy as that ;-)
I do not want to make you look dumb Petr. My goal is to save us all 
time and keep important information stored, so we don't have to go 
through the same discussion(s) again. I will put your final wishlist 
note in the file, so when this comes up again, you can just direct 
people to it. See, I'm saving you time too. :-)
If you want to extract any other comments from this chat, and include 
them there, to clarify your desires, that would be great.
As far as the wish for a View/VID native solution goes, I wish that 
as well. Maybe it will be possible when the JIT compiler becomes 
reality to easily adapt Rebol's VID. 

It does not have to be complete like VID, a basic set of widgets 
will get you a long way.  

Other solutions are a really good thing too, but looking at GTK and 
myself I find it hard to find out how to get GTK on my mac. It is 
not a standard dmg file I can download and install and it works. 
Other GUI solutions require integration of their package or having 
the end user of your programs to find out how to get it running on 
their machine. That kind of thing can be a real showstopper to global 

I know Doc is working hard and has already stated he intends to come 
up with a VID like native solution. So we can let him focus and be 
silent ,or we can comment and discuss letting him know we do care.
Should FUNCTION not be the same as FUNC ? Because FUNC is primarily 
the preferred way to spell FUNCTION for shorter. And FUNCT is than 
the special case that uses only local variables?
I can do this in C, define something based on another defination 
=> #define a 0 #define b (a + 1) ... Can I do the same thing in Red/System?
This prints 15 for me:

#define a 10
#define b [a + 5]

print [b lf]
Hun, So we did can do that in Red/System ... Thanks, Peter.
It even works if b is defined before a:

Red/System []

#define b [a + 5]
#define a 10

print [b lf]
Arnold: I think that FUNCT is an interesting function constructor, 
but has a horrible name, and as FUNCTION is rarely used, I thought 
it would be good to make it act like FUNCT, it will be easier for 
newcomers and look less awkward than the truncated FUNC name. Also, 
we might want to make FUNCTION act the same way in Red/System (I 
don't remember if there was some show-stopper for that).
Agreed FUNCT is a horrible name!
Not that it matters to you, but my code uses FUNCTION which comes 
from R1, in fact
Shouldn't /extern take a non-block, like /local? It seems confusing
It is not equivalent to /local, because locals variables can have 
a type specifier and doc-string, while external variables not.
AltMe is really bad for keeping up with more than one single topic 
at a time. The discussion about the Red documentation slipped away, 
while being a very important question to me where I need feedback 
and inputs. So I would like to resume it. 

What should Red reference documentation look like ideally?
I guess the REBOL docs are a good model to start with. They're pretty 
good, although they're sometimes too clinical. I would like them 
to give more advice on gotchas and background information. Official 
documentation has mostly carefully avoided explaining how REBOL works
If you want to do something fancy, you could add interactive examples, 
like on http://w3schools.com
My thoughts - All documentation needs to be in a single location. 
It should comprise 3 main sections 1) Explanation of how rebeol works 
- like core manual plus inner working of Rebol - the theory, 2) Reference 
of every word with samples of how to use the each word - must be 
exhaustive, 3) Tutorials split into novice, intermediate and advanced 
- all with examples. Current Reboi documentation is much better now 
but is still too scattered and fragmentary and not enough examples 
on how to use each word. Anything in Red that is not documented will 
be a cause of frustration and will result in lack of use. Plan to 
do the documentation for someone who has never heard of Rebol and 
Red that way less corners will be cut and important information will 
not be assumed to be known.
Sorry for Rebol - read - RED
I think in sequence of creation, the reference should be done first.
Henrik, I agree. However, documentation that just regurgitates the 
api that can be gleaned with "help" word is next to useless - documentation 
needs to explain a lot more about a word than the api does - iat 
least: ts reason for existence, how to use it, and examples of usage.
yes, the R3 reference is functional for this. Initially it fills 
the skeleton parts that contain the same information as help, but 
it works like a wiki, where each page can be filled with examples. 
I think comments were planned as well, but that never came about.
when it comes down to it, I want every function to be documented 
in the reference with every defect, caveat, bugs, tricks and whatever 
can be found.
One example of a reference that I find very useful is the Clojure 
cheat sheet. The one one clojure.org doesn't have tooltips, but some 
do. The nice thing is that all link to the clojuredocs.org site which 
is a great for crowdsourcing usage examples, including notes, caveats. 
For sure Red should have something similar.


I don't know how it stands up to "modern" standars wrt interactive 
documentation, but I know that Gigaspaces won some kind of award 
for the organization/presentation of their developer documentation 
- this was a few years ago when I was investigating the technology.

Good example docs from Closure - very comprehensive and helpful - 
something like that with tutorials and theory would be cool