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

World: r3wp

[!REBOL3-OLD1]

BrianH
28-Oct-2008
[7804]
You may be off in looking for practical reasons for thin skins - 
that is a reason why I chose Winamp as an example. Still, if you 
want a practical example, there is a Chinese version of OpenOffice.org 
that uses a vertical version of Office 2007's ribbon interface instead 
of OOo's menus. That is the kind of thing that would be possible 
with thick skins.
Pekr
28-Oct-2008
[7805]
So thick skin allows complete change to layout, while the lower layers 
stay identical?
BrianH
28-Oct-2008
[7806]
Yup. Complex styles are laid out like panels. Their layout is just 
as easy to change.
PeterWood
29-Oct-2008
[7807]
I disagree with "it doesn't matter what strings are internally". 
If Rebol3 is going to be extensible as promised, the internal representation 
of all dataypes matters.
Henrik
29-Oct-2008
[7808]
If you want precise control of the content of string data, use binary. 
String! is no longer meant to be used for such tricks.
Pekr
29-Oct-2008
[7809]
From file list example: "text-list files do [set-face ca read-string 
pick files value]" - where does the 'value come from? Is it internal 
facet of 'text-list style?
PeterWood
29-Oct-2008
[7810]
If by "precise control" you mean accessing a string! from C, how 
would you use binary! instead?
Gabriele
29-Oct-2008
[7811x2]
string! internals are not OS dependent afaik, and technically it's 
not UTF-16 either. currently, R3 switches automatically between an 
array of 8-bit unsigned values, and an array of 16-bit unsigned values. 
i assume a 32-bit mode will be added in the future as not all codepoints 
will fit 16 bits, though those that don't are very rare.
Peter, if you're talking about plugins, then you *won't* have *direct* 
access to the internal datatype representation, but there is always 
an abstraction layer. in any case, that abstraction layer hasn't 
been finalized yet, so, at this point it doesn't matter what strings 
are internally.
PeterWood
29-Oct-2008
[7813x3]
Thanks for the information, Gabriel. Yes, I was taking about plug-ins. 
It will be interesting to learn of the details once things have been 
worked out.
Is the array to 16-bit unisgend values effectively UCS-2?
Sorry that should have been :

Is the array of 16-bit unsigned values effectively UCS-2?
Henrik
29-Oct-2008
[7816]
Pekr, yes, VALUE comes from the face itself, just like in old VID.
Pekr
29-Oct-2008
[7817]
Henrik - thanks for third video. Still uses lower frame rate? Scrolling 
still seems being rather slow. It will probably need some optimisations 
by Cyphre in low level ...
Henrik
29-Oct-2008
[7818x2]
Pekr, it was meant to be 40 fps, but it ate almost 100% CPU. Rendering 
is usually about twice as fast.
h264 realtime encoding is CPU intensive :-)
Pekr
29-Oct-2008
[7820]
I was referring to subpanel, seems slow anyway. When you run R3 alpha 
script called button-colors.r, it is painfully slow. I asked Cyphre, 
and he told me it would need some optimisations. Those things really 
should be realtime, or we will not be able to write Office 2007 clone 
in R3 :-)
Henrik
29-Oct-2008
[7821]
I'm not sure if it's related. Carl has only just inserted this feature, 
so I don't know what optimizations are missing. I would guess it 
does very excessive ON-DRAW on each of the faces in the panel.
Pekr
29-Oct-2008
[7822]
what is on 061.png? Just boxes? :-)
Henrik
29-Oct-2008
[7823]
just boxes
Pekr
29-Oct-2008
[7824x2]
For the fans of REBOL - bbrv posted new blog. You can see there an 
advert, containing ED set-top-box. It was done during Viscorp times 
in 1996, when Viscorp was about to take over Amiga from Escom. OS 
was done by Carl Sassenrath, Jim Goodnow, and Carl even talked RJ 
Mical to join the group. The project was fiasco, but look at the 
screenshot. ED set-top-box UI was done in ABL\E, predecessor of REBOL 
...
http://bbrv.blogspot.com/2008/10/everything-everywhere-ii.html
BrianH
29-Oct-2008
[7826x4]
Pekr, subpanel was slow on Henrik's demo because of his debug settings.
Peter, the array of unsigned values would effectively be UCS-2 if 
it behaves the way Gabriele says. This would mean it would be faster, 
but use more memory for those with characters outside the BMP. It 
would also cause a problem on Windows because Windows >= 2000 is 
internally UTF-16, as are all of its Unicode APIs.
You could store UTF-16 in an array of unsigned 16-bit values as long 
as your length, insertion and deletion routines are UTF-16 aware.
INDEX? and LENGTH? would be O(n) though.
Pekr
29-Oct-2008
[7830]
Henrik - you'r from Germany? :-)
Henrik
29-Oct-2008
[7831]
no :-)
Pekr
29-Oct-2008
[7832]
Then contact Carl to fix his blog :-)
Henrik
29-Oct-2008
[7833]
I did :-)
Pekr
29-Oct-2008
[7834]
why debug red lines can't be seen, if full gob size is utilised? 
Can't it be layered inserting new gob into gob/pane?
Henrik
29-Oct-2008
[7835]
It's not supposed to be seen, because otherwise I wouldn't be able 
to see the lines that are supposed to occupy those pixels by the 
style itself. The debug function is activated like this:

view [button "hello" debug]


and the red box appears in the face, not around it. The red box stretches 
to the very edge of the gob, so you can see where you draw.


The box is generated in the same draw block, by simply inserting 
a red box in the beginning, if the debug flag is enabled.

Having this box, helped us solved numerous layout bugs.
Pekr
29-Oct-2008
[7836]
Yes, but why not insert it at the tail then? Because, when not seen, 
it does not work for you, no? What about styles, which do utilise 
the whole gob size?
Henrik
29-Oct-2008
[7837]
Read the first line in my response for your first question. :-)
Pekr
29-Oct-2008
[7838x2]
Anyway - I was surprised by addition of debug modes. It will greatly 
improve situation over R2 VID.
... when you debug, you don't want to see your lines that are supposed 
to be there :-)
Henrik
29-Oct-2008
[7840]
The second question: Some styles will occupy the entire gob size, 
yes. That's no problem. The red box is mainly there to display where 
the border is on the gob. Nothing else. I had great trouble aligning 
styles without it.
Pekr
29-Oct-2008
[7841]
your site's down ....
Henrik
29-Oct-2008
[7842x2]
Pekr, correct.
I see, perhaps it's one of the mysterious Cheyenne crashes.
PeterWood
29-Oct-2008
[7844]
BrianH: As I understand UCS-2 cannot be used to encode characters 
outside the BMP. It is a full subset of UTF-16. It should not cause 
problems with WIndows Unicode API except that it would not be able 
to display characters outside the BMP. (It would instead include 
 an non-displayable character for each 2-bytes returned by Windows.)
BrianH
30-Oct-2008
[7845]
The problem would come from the Windows API returning characters 
that can't be handled which would appear to REBOL as 2 non-displayable 
characters, or REBOL code inserting characters inbetween double characters 
by accident, or copy grabbing partial characters.
Pekr
30-Oct-2008
[7846x2]
Henrik - re your new screenshots - calculator - what is the reason 
grouped buttons of math operations are not precisely aligned vertically 
(at the bottom) as the num pad? Is it a bug in layout, or is it like 
it should be?
e.g. numbers 68, 69 ....
Henrik
30-Oct-2008
[7848]
Pekr, illustrations for Carl to use for fixing those alignment bugs.
Pekr
30-Oct-2008
[7849]
Henrik - is the gradient type/structure the same for the above mentioned 
calculator buttons and for the normal buttons in another screenshots? 
That calculator one looks good. But maybe it is because of white 
text color ....
Henrik
30-Oct-2008
[7850]
The button style is called MINI-BUTTON and is derived from BUTTON. 
It's meant to be used in groups and confined spaces. It took about 
5 minutes to write. The font is custom for this application.
Henrik
31-Oct-2008
[7851]
BrianH, can you talk about the set [a: b:] issue and what it means 
for us?
Gabriele
31-Oct-2008
[7852]
Brian: same as there is a conversion between the Linux UTF-8 APIs 
and the internal 16 bit array, there is a conversion between the 
Windows UTF-16 APIs and the internal 16 bit array. In the same way, 
we can eventually support 32 bit arrays and convert those UTF-16 
strings that can fit into it to just 8 bit arrays.
BrianH
31-Oct-2008
[7853]
Gabriele, cool, I was just concerned about speed. I suppose calls 
to external APIs are likely to be less frequent than internal manipulations, 
and UCS encoding would make the internal code faster. Either way 
I'm sure that it will be handled :)