You will get poor results using anything less than 8.5. There are serious bugs in the 8.4 branch, especially with font handling on GNU/ Linux. If you are on a Debian system, you can do:

apt-get install tcl8.5 tk8.5
update-alternatives wish

Then choose wish8.5.  Pd 0.42 should be fine with 8.5.

.hc

On Aug 25, 2010, at 5:50 PM, cyrille henry wrote:

8.4.19
c

Le 25/08/2010 22:58, Hans-Christoph Steiner a écrit :

Which wish are you using?

$ wish
% info patchlevel
8.5.8

.hc

On Wed, 2010-08-25 at 22:30 +0200, cyrille henry wrote:
hello,

withubuntu 10.04

pd -noprefs
->  the message box are higher than the text
pd -noprefs -font-face "andale mono" solve the problem

so, andale mono is here, but not used...



here is the result of your script.

linespace       ascent          descent         font name
---------------------------------------------------------------
13              11              2               msbm10
13              11              2               webdings
13              11              2               fixed
18              15              3               lucidatypewriter
19              14              5               courier 10 pitch
13              11              2               cmsy10
21              17              4               andale mono
14              11              3               clean
17              13              4               terminal
16              14              2               gothic
13              11              2               cmr10
13              11              2               wenquanyi zenhei
16              14              2               song ti
37              15              22              open look cursor
13              11              2               cmex10
16              14              2               mincho
13              11              2               msam10
18              14              4               courier
13              11              2               inconsolata
16              16              0               nil
13              11              2               cmmi10
16              14              2               fangsong ti
20              16              4               dotum
28              17              11              courier new
18              14              4               nimbus mono l
20              16              4               batang
13              11              2               wasy10

Cyrille

Le 25/08/2010 21:39, Hans-Christoph Steiner a écrit :

I figured out the cause. The problem is caused by the font used being different than the font that fits into the standardized boxes. If you have the margin problem or the offset clicking problem then your Tcl/Tk is not used "DejaVu Sans Mono" or "Andale Mono", the two fonts I have
found that fit into the standard box size.

Other fonts have different ratios of height to width, and when Pd uses a different font, it tries to size it larger to fit the DejaVu Sans Mono. Also Tcl/Tk 8.4 does a bad job of font handling on GNU/Linux/ X11. 8.5
is better but different than 8.4.

The DejaVu fonts are the standard fonts for GNOME and are included in all major distros, so those seem the natural font to standardize on.
Also, DejaVu Sans Mono looks pretty good.

To get an idea, run the attached script with your wish. It would be quite useful if people would post the results of that script here so we
can see what fonts are commonly available.

.hc

On Wed, 2010-08-25 at 11:49 -0700, Miller Puckette wrote:
By 'margin' I meant that 'the box is larger than the text inside it so there's a bunch of empty space inside it'... if you don't see that you won't have the
problem I'm having :)

M

On Wed, Aug 25, 2010 at 02:45:12PM -0400, Hans-Christoph Steiner wrote:

Ok, testing now... as for having the boxes with a standardized size, that's been the case with Pd-extended 0.40 and is also the case with 0.43 as of now. I'm not sure if I understand your idea about the margin
tho, but an outline in edit mode sounds like a good idea.

.hc

On Wed, 2010-08-25 at 11:09 -0700, Miller Puckette wrote:
Sure...  here:

#N canvas 359 131 405 427 10;
#X msg 98 55 \; line 1 \; line 2 \; line 3 \; line 4 \; line 5 \; line 6 \; line 7 \; line 8 \; line 9 \; line 10 \; line 11 \; line 12 \; line 13 \; line 14 \; line 15 \; line 16 \; line 17 \; line 18 \; line
19 \; line 20;

On my machine the text box is several (20?) pixels too tall and to select
the bottom line of text you have to click way below it.

I don't see how the thing can be made truly cross-platform unless there's a way to get text to have a determined size (both vertical and horizontal)
and that seems to be impossible to get to work cross-platform.

The only solution I can think of for getting boxes to have consistent sizes is to use Mathieu's suggestion and make the box have a standardized size, simply adding margin when the text font doesn't actually fill it. (There's have to be an outline drawn around comments when the patch is unlocked too.)

cheers
Miller

On Wed, Aug 25, 2010 at 12:15:11PM -0400, Hans-Christoph Steiner wrote:

I think the real solution to this would be one step deeper. If Pd used Tcl to handle the GUI interaction, then we could use the Tk
scaling feature, which is what Tk does to handle cross-platform
differences in font rendering. Pd could then store the Tk scaling number in the patch, and use it to scale internal copies of pixel values, when necessary. Then we could have the best of both worlds. This would also give us the ability to zoom/scale patches for free.

This is not as hard as it might seem, I believe DesireData has this
working.  I think this would also be quite clean and actually
simplify Pd's code rather than adding more complexity by tracking both when fonts should fit to the box size and when the box size
should fit to the font.

I'll take a look at the big text block clicking issue now. Do you
have an example patch?

.hc


On Aug 24, 2010, at 4:38 PM, Miller Puckette wrote:

Long as there's a way to fix a problem I'm having:  in message
boxes with
many lines of text, you can easily click on one character and
select one above
it... it gets very confusing.  (Fedora 13 out-of-box).

I'm guessing that in the current version the GUI simply tells Pd
what size
the font ought to have had instead of the genuine one. Pd could
easily
expand the box to the ought-to size (at least optionally for those
wishing
to make cross-platform patches) but should know about the text's
actual size
anyway.  To be continued...

cheers
Miller

On Tue, Aug 24, 2010 at 01:21:08AM -0400, Hans-Christoph Steiner
wrote:

On Aug 23, 2010, at 7:01 AM, Frank Barknecht wrote:

Hi,

On Sat, Aug 21, 2010 at 01:39:08PM -0400, Mathieu Bouchard wrote:
BTW I've been using Pd-Extended's Linux/OSX default font
size as the
basis for all my patches for making my last 400 patches or so.

I've used Pd vanilla for all my patches so far, with a "10"
font-size,
whatever that is in pixels. I know, that Pd-extended uses some
different
layout for several years now, which makes patches look wrong
when you
load them in Pd vanilla and the other way around. I have not much interest to discuss the differences between vanilla and Pd- x,
as I am
hoping the two to unify again with the gui-rewrite. So I'm
willing to
change my preferences to whatever will be the new vanilla, but I'd prefer to not do again that with every release or with every new Courier-like font that pops up on the Internets' Top 10 console font
lists and is so much better than the previous ones.


Unless Miller changes it in the future, Pd 0.43 should have the same boxes sizes that Pd-extended has had for a couple versions. That was one of my goals with the GUI rewrite. Its a bug if that's not
the case.

.hc


----------------------------------------------------------------------------

The arc of history bends towards justice. - Dr. Martin Luther
King, Jr.



_______________________________________________
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management ->   
http://lists.puredata.info/listinfo/pd-list




----------------------------------------------------------------------------

You can't steal a gift. Bird gave the world his music, and if you
can hear it, you can have it. - Dizzy Gillespie








_______________________________________________
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management ->   
http://lists.puredata.info/listinfo/pd-list



_______________________________________________
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management ->  
http://lists.puredata.info/listinfo/pd-list



----------------------------------------------------------------------------

I spent 33 years and four months in active military service and during that period I spent most of my time as a high class muscle man for Big Business, for Wall Street and the bankers. - General Smedley Butler



_______________________________________________
Pd-list@iem.at mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list

Reply via email to