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

World: r3wp

[View] discuss view related issues

Graham
14-Oct-2008
[8225x2]
even better
Anyway, excellent way to get a screen print of a View layout
Henrik
14-Oct-2008
[8227x2]
it's almost stupidly simple. :-) it's one of those things I wish 
I came up with 2-3 years ago. could have saved a lot of work. the 
secret is just to slavishly follow the offsets and sizes already 
generated with VID or RebGUI.
no fancy postscript measuring tools are used.
Graham
14-Oct-2008
[8229]
I'm not sure it would work with microjustification of text
Henrik
14-Oct-2008
[8230]
we don't have finer type setting features, but I can live with that, 
as long as I have a simple and quick way to build postscript pages.
Graham
14-Oct-2008
[8231]
can you get that type of resolution with View?
Henrik
14-Oct-2008
[8232]
if you scale your view up and then appropriately scale the postscript 
down, yeah
Graham
14-Oct-2008
[8233]
scale it up so that it's too big for the screen?  :)
Henrik
14-Oct-2008
[8234]
yes, you can create 10000x10000 layouts if you want to, they just 
won't fit on the paper without scaling them down. I did something 
similar once in a different system, but it proved to be unusably 
slow on smaller PCs and it eats memory.
Graham
14-Oct-2008
[8235]
yes
Henrik
14-Oct-2008
[8236]
I may add scaling, if it makes sense
Graham
14-Oct-2008
[8237]
So, will this work images etc?
Henrik
14-Oct-2008
[8238x3]
image support depends on if postscript.r will get support for image!. 
currently it seems only to support direct loading of jpg, gif and 
bmp images.
image! support is necessary if we want to output the face/image and 
face/effect parts of a face
scaling now added. use to-postscript/scale my-layout 0.1 to increase 
precision by 10 times. this means you must create your layout 10 
times bigger.
Graham
14-Oct-2008
[8241x2]
so what elements can you support now?
text and ?
Henrik
14-Oct-2008
[8243]
text and boxes
Graham
14-Oct-2008
[8244]
ok
Henrik
14-Oct-2008
[8245x2]
DRAW is probably too hard to get in. I don't personally need it.
perhaps we should move this to the postscript group
Anton
14-Oct-2008
[8247x2]
Can you put bitmaps in a postscript file ?
(moved to Postscript group)
PeterWood
30-Oct-2008
[8249]
I've come across what seems to be an oddity with View on the Mac.Iit 
seems that the Rebol/View console is using UTF-8 encoding but that 
View is using MacRoman.
Gabriele
31-Oct-2008
[8250]
the "console" on Mac and Linux is just a terminal (OS provided), 
and they are usually UTF-8. That has nothing to do with View.
Robert
1-Nov-2008
[8251]
How can I return something when using DISPLAY/DIALOG when the dialog 
is closed? Something like:

result: display/dialog [...]

Or is this only possible via a wrapper function?
Graham
1-Nov-2008
[8252x2]
Sounds like Rebgui
display returns the layout ...
btiffin
1-Nov-2008
[8254]
Or  maybe

catch [display/dialog "test" [button "button" [hide-popup]] throw 
"result"]
which is equivalent to a wrapper function I guess
Gabriele
2-Nov-2008
[8255]
btiffin, why would you need the catch and throw there?
Robert
2-Nov-2008
[8256]
I solved it now by writing a function that collects and returns the 
result. And this function contains the DIALOG stuff.
btiffin
2-Nov-2008
[8257]
Sorry, this was an attempt to get round the none returned when the 
sysclose is used ... did I go overboard?  could be
Gabriele
3-Nov-2008
[8258]
what i meant was, why not just do [ display ... "result"] ?
btiffin
3-Nov-2008
[8259]
Yep.  Pull head out; breathe.  ;)
Henrik
4-Nov-2008
[8260]
Does anyone know how to adjust the saturation of a single RGB value?
Gregg
4-Nov-2008
[8261]
Chris Ross-Gill might know. He's done a number of color adjustment 
bits.
Henrik
4-Nov-2008
[8262]
It's interesting that I can find tens of places with getting the 
saturation of an RGB value, but not the other way around. I must 
be asking the wrong question.
Pekr
4-Nov-2008
[8263]
Henrik - the only thing I do remember from View 1.3 dev times is 
addition of rgb-to-hsv and hasv-to-rgb functions.....
Henrik
4-Nov-2008
[8264x2]
yes. They appear not to be present in R3.
(which is kind of fortunate, because I spent the whole day building 
them :-))
Pekr
4-Nov-2008
[8266]
IIRC, there was first a source version from Chris, then it was added 
as a native ...
Chris
4-Nov-2008
[8267x3]
http://www.ross-gill.com/r/hsv-lab.r
It's not exactly equivalent, rgb-hsv returns a block.  It's also 
a little slower...


[hue [integer!] saturation [decimal!] brightness [decimal!] alpha 
[decimal!]]
Hmm, also in the library:

http://www.rebol.org/view-script.r?script=hsv-lab.r
amacleod
4-Nov-2008
[8270x4]
Is there a way to get an index # from a text list selection?
text-list
face/text gives the string but can I get its position i the list?
actually its face/picked gives teh string..
Chris
5-Nov-2008
[8274]
index? find face/data face/picked