Re: Prima & Debian

From: Dmitry Karasik <dmitry_at_karasik.eu.org>
Date: 24 Nov 2003 11:33:26 +0100
To: prima_at_prima.eu.org

        Hi Serge!

On 24 Nov 03 at 10:28, "Serge" (Serge Olkhowik) wrote:

 Serge> There is no 1.13 at http://www.prima.eu.org/download/, just
 Serge> http://www.prima.eu.org/download/Prima.tar.gz and I don't know
 Serge> whether this is 1.13? So I tried CVS.

True, in the section 'previous releases' there is no 1.13, since
Prima.tar.gz is the latest, which for today is 1.13.
A bit confusing.

 Serge> perl Makefile.PL INSTALLSITEARCH=`perl -MConfig -e 'print
 Serge> "$Config{installvendorarch}\n";'`

 Serge> So I specify perl Makefile.PL PREFIX=.... but it isn't enough :(

 Serge> INSTALLVENDORARCH would be nice in my case:

 Serge> % perl -MConfig -e 'print "$Config{installvendorarch}\n";'
 Serge> /usr/lib/perl5

 Serge> % perl -MConfig -e 'print "$Config{installsitearch}\n";'
 Serge> /usr/local/lib/perl/5.8.1

Aha, I see now why MakeMaker uses INSTALLDIRS, so on debian
one uses INSTALLDIRS=vendor - smart enough.
I think that The Right Thing to do would be to teach Makefile.PL to understand
INSTALLDIRS the way ExtUtils::MakeMaker does. If you'll come with a patch
that would be grand.

 Serge> How can I check for xft?

ldd Prima.so | grep Xft

 Serge> I ran xfontsel -pattern '-*-arial-medium-r-*-*-14-*-*-*-*-*-koi8-r'
 Serge> but it looks normal as contrary to simple Prima example.

 Serge> Please look at these windows shots:

 Serge> http://www.bamba.dp.ua/Prima/prima-xfontsel.png
 Serge> http://www.bamba.dp.ua/Prima/prima-koi8.png

Prima never fully trusts the font names given from outside, this
explains why the fonts CAN be different. To find out why these particular
two are different, run it with --debug=mf .

 Serge> I wrote simple example in koi8 and it worked. But it worked with
 Serge> .Xresources file only. I tried even --font=Tahoma-16 - none happens
 Serge> :(

1.13 only.

 Serge> So I changed my script for utf-8 (added 'use utf8;', changed
 Serge> 'coding: utf-8') and I got:
 Serge> http://www.bamba.dp.ua/Prima/prima-utf.png
 Serge> And any --font doesn't affect button text.
 Serge> So I have to modify my .Xresources:
 Serge> Prima*font: -*-arial-medium-r-*-*-14-*-*-*-*-*-*-*
 Serge> and text is ok (and it's still small). But my koi8 script fails ;)
 Serge> So what I have to do?

Try setting LANG to koi8 locale, otherwise Prima wouldn't know
which encoding to use for -*-arial-medium-r-*-*-14-*-*-*-*-*-*-* .
If you set a default unicode font with koi8 charset present, you can use
both koi8 and utf8 simultaneously.

 Serge> Can you point me to any documentation how I can specify font for
 Serge> special widget? Is there any methods to specify some options (font,
 Serge> colors, borders, styles and so on) for all widgets of application?
 Serge> (I can do this with resources when initializing Perl/Tk
 Serge> application)

Standard XRDB way, but fonts and colors only:
  Prima.MainWindow.backColor: yellow
  Prima*Button.font: 12-Arial

This is one of rare undocumented parts. --debug=x can help
discovering internal Prima to X resource name conversion.

 Serge> Where can I find documentation about geometry management (pack)? I
 Serge> found some about 'pack =>' option in examples but I think this
 Serge> isn't enough. I need information about something like Perl/Tk
 Serge> frames.

man Prima::Widget::pack . I have no deep knowledge about the frames, but
IMO one can simply use Prima::Widget for same ( grouping ) function as
Tk frames. If the Tk frames are more capable, I'll be curious to know.

-- 
Sincerely,
	Dmitry
--- www.karasik.eu.org ---
He who dies with most the toys wins
Received on Mon 24 Nov 2003 - 11:33:34 CET

This archive was generated by hypermail 2.2.0 : Sat 19 Mar 2011 - 18:35:05 CET