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

World: r3wp

[Postscript] Emitting Postscript from REBOL

Graham
15-Apr-2006
[582]
the print button, unimplemented, would send the post script file 
to your printer.
Henrik
15-Apr-2006
[583x3]
wow
that's really all I can say at this point
graham, out of curiosity, can you scale as you want? could you implement 
a slider? I'd like to see how fast it is.
Graham
15-Apr-2006
[586]
Yes, could implement a slider .. if I can remember how to do sliders!
Henrik
15-Apr-2006
[587]
SLIDER in the layout and then use /data to extract the position which 
is between 0 and 1
Graham
15-Apr-2006
[588x8]
:)
There's a free postscript viewer and allows you to print in windows 
here: http://www.rops.org/
It's http://www.rops.org/download/freescript53.exeand does only 
Level 1.
a measly 324Kb.
Uses windows installed fonts instead of postscript fonts to preview 
and print.
http://www.compkarori.com/reb/psd2draw.r
has a slider now for Henrik :)
it gets all screwed up when really small.
Henrik
15-Apr-2006
[596]
the fonts scale a little funny
Graham
15-Apr-2006
[597]
Just uploaded a newer version that places the slider vertically.
Henrik
15-Apr-2006
[598x2]
I thought there was subpixel accuracy
it scales transforms as well, it seems
Graham
15-Apr-2006
[600x4]
Perhaps I've done something wrong.
that gray box is not right.
as you scale it, you can see it moving closer to the other box.
It is supposed to be superimposed on the other box from the start.
Henrik
15-Apr-2006
[604x2]
no it moves and rotates. maybe SCALE is working too well?
As in, scales all transform parameters
Graham
15-Apr-2006
[606x2]
Text does undergo scaling or rotations.
*doesn't
Henrik
15-Apr-2006
[608]
what if you convert the text to vectors?
Graham
15-Apr-2006
[609x3]
could do ... use vectorial text.
I didn't try.
For those without postscript printers, using the free version of 
rops.exe might be a solution for them.
Henrik
15-Apr-2006
[612]
there is a free version?
Graham
15-Apr-2006
[613x5]
I'm hoping someone who knows more about draw can fix this for me 
:)
free version of rops is level 1 ps.
the versions that cost do level 2 and 3.
http://www.rops.org/download/freescript53.exewhich is the free version 
for windows
I got the impression that AGG draw is skewed a little to assist producing 
SVG graphics .. but there's a strong case to support postscript better 
instead.
Geomol
15-Apr-2006
[618]
Looks good, Graham. I hope to get time one of the comming days to 
investigate PS a little more, so the dialect can be more complete. 
I like your idea about getting rid of blocks, and I hope to make 
a consistent version with few blocks, maybe only for font.
Gabriele
15-Apr-2006
[619]
text in draw can only be transformed if rendered in vector mode
Graham
15-Apr-2006
[620]
changing the text to vector mode now has the text obeying the rotation.
Henrik
15-Apr-2006
[621]
did you upload that one?
Graham
15-Apr-2006
[622x9]
no.
text: [err:
		set txt string! (
			fontcount: fontcount + 1
			set to-word join "font" fontcount  make face/font compose [
				 size: (fontsize) 
				 name: (fontname) 
				 color: (rgb)
			] 
			pos/y: pos/y - fontsize

   repend output  [ 'font (to-word join "font" fontcount) 'pen rgb 'text 
   'vectorial txt pos ]
		) 
	]
Of course vector fonts look quite different.
So, I can't see much use for my purposes.
Times-Roman
 "Times New Roman"
		"Courier" 		"Courier New"
		"Helvetica-Oblique" "Arial Italic"
		"Helvetica" "Arial"
		"Times-Oblique" "Times New Roman Italic"
		"Helvetica-Oblique" "Arial Italic"
		"Courier-Oblique" "Courier New Italic"
		"Times-Bold" "Times New Roman Bold"
        "Helvetica-Bold" "Arial Bold"
		"Courier-Bold" "Courier New Bold"
		"Times-BoldOblique" "Times New Roman Bold Italic"
		"Helvetica-BoldOblique" "Arial Bold Italic"
		 "Courier-BoldOblique" "Courier New Bold Italic"
Can someone check these to see if they are correctly matched ?  The 
left hand is the postscript font, and the right hand is the true 
type font
I'm not sure about Times ...
these http://www.rops.org/download/std35ttf.zipare the ghostscript 
GNU fonts equivalent to the 35 postscript fonts
so, you can install these and get pretty exact matching.  You'll 
have to change the lookup table above.
Maxim
15-Apr-2006
[631]
I always thought arial was wider than Helvetica in aspect... but 
I've never really compared them to see if they are really the same 
font...