[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Re: gEDA-dev: libgeda, gschem: New print dialog
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi
> Stop... the Prolog is copied verbatim from a file, and everything
> between the end of the DSC comments and the %%EndProlog comment
> should be exactly the same between runs of the tool.
See below for a diff between the original postscript file and the file
with bigger fonts. Note that the first chunk is in the prolog and is
constant. The second chunk is just after prolog where the printing
function already puts similar definitions.
> If we need a fudge factor applied to the size of the text, then that
> can be done too. There is a much better place to do so. It's in
> the text output routine. There, a calculation is done to scale the
> internal measure of the text size 'points' to the postscript units.
> This is the logical choice for such a change, it keeps the
> information together in one place. Imagine someone later coming to
> try to figure out why his/her text comes up strange sizes and not
> being able to find where the scaling is occurring...
I guess you are right.
Well, currently this works for me and it is quite simple. I don't want
to dive into libgeda printing code and the font size doesn't seem to
bother anyone else, so I'll just forget about the patch.
> Note also, that there is the possibility that the text is also output
> as vectors, changing scale there might be a bit more difficult, as
> it uses the primitive line drawing routines to render the text.
As far as I see text is not drawn with lines in the postscript file (it
is drawn that way on the screen though)
Best regards
Tomaz Solc
- --- nacrt.ps 2006-08-02 15:41:12.000000000 +0200
+++ nacrt-new.ps 2006-08-02 15:42:06.000000000 +0200
@@ -321,11 +321,11 @@
gsave % save state for later
dup /fontsize exch def % save font size for corrections later
% do font selection
/gEDAFont findfont
- - exch scalefont
+ exch fontcorrectionfactor mul scalefont
setfont
% set up coordinates
translate % move origin to given point
rotate % rotate so that text is drawn
@@ -398,10 +398,11 @@
%%EndProlog
%%Page: 1 1
/gEDAFont ISOLatin1Extended /Helvetica RE
+/fontcorrectionfactor 1.6 def
2 setlinecap
0.072000 0.072000 scale
7441 500 translate 90 rotate
0.218579 0.218579 scale
-59470 -37680 translate
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFE0K/ssAlAlRhL9q8RAgjiAKCpEdgnGL1qT/+/QIZuFhO+IiQE8wCgzEE9
IcpDYJ5jOpViXLbQztJIing=
=4826
-----END PGP SIGNATURE-----
_______________________________________________
geda-dev mailing list
geda-dev@moria.seul.org
http://www.seul.org/cgi-bin/mailman/listinfo/geda-dev