(OLD) (ARCHIVED) Puppy Linux Discussion Forum Forum Index (OLD) (ARCHIVED) Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info

This forum can also be accessed as http://oldforum.puppylinux.com
It is now read-only and serves only as archives.

Please register over the NEW forum
https://forum.puppylinux.com
and continue your work there. Thank you.

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups    
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Tue 20 Oct 2020, 13:23
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
font2font - a better pfontview?
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies. View previous topic :: View next topic
Page 1 of 1 [5 Posts]  
Author Message
MochiMoppel


Joined: 26 Jan 2011
Posts: 2084
Location: Japan

PostPosted: Thu 25 Jun 2020, 22:42    Post subject:  font2font - a better pfontview?  

In one of my recent comments on pfontview, Puppy's standard font viewer, I argued that this tool needs not only a fix but a rewrite.

I tried that, and the result is IMHO opinion more useful, but finally that's not for me to decide, so I'll better add a questionmark to my claim. I decided to do a complete rewrite because I wanted more functionality with less code and less files. Since I didn't use a single line of the original code I also had to come up with a new name.

What's different in font2font
⚫ Apart from TTF and OTF files, full support for TTC and PFB files

⚫ The selected font is always compared to a second font. I find it hard to judge a font by staring at the glyphs. Often only when I compare the font to a similar font I can see differences. And even when the glyphs look almost identical, the width very often is not.

⚫ No more jumping foxes. The preview text is customizable, can be changed on-the-fly and of course can be saved. This also eliminates the need for an extra preview entry field.

⚫ Preview size can also be changed on-the-fly (up to size 200)

⚫ No "style" display for the selected font. I've come to the conclusion that the "style" element is almost useless. It's just a more or less fancy name like the font name and may or may not reflect the characteristics of a font. It's all up to the font author to name the style. Interestingly the GTK font button for the comparison font returns a style calculated based on the font metrics, ignoring whatever name was selected in the dialog. E.g. in my font "Jedi" the style is named "Normal", but the GTK button returns "Jedi Bold Semi-Expanded" because weight is 200 and width is 113. This label would be added to the darkred name of the comparison font while "Jedi Normal" would be the label for the font button. Utterly confusing. That's why I let the font button only show the font name but not the style.

⚫ An additional Info diplay shows font properties and metrics. Here the user can see the "style" name(s) and more important information like weight or width.

⚫ The Save button will, among other things (see tooltip), save window position, not just window size.

⚫ font2font uses much less files (3 files vs. 18 files for pfontview, not including the obsolete sfontview).

⚫ Can be called without an argument (sometimes useful for testing)

What's the same
⚫ Ability to preview uninstalled fonts (by temporarily installing font for the duration of preview). Hmm, this sentence makes no sense but I hope you get the idea anyway.

⚫ Installation. There is none. Just copy script to /usr/bin, make executable if needed and associate TTF,TTC, OTC, PFB files in ROX-Filer by right-clicking such file, select "Set Run Action" and edit the command. Alternatively create a desktop icon and drag font files onto it.
font2font.gz
Description 
gz

 Download 
Filename  font2font.gz 
Filesize  2.61 KB 
Downloaded  114 Time(s) 
font2font.png
 Description   
 Filesize   113.68 KB
 Viewed   299 Time(s)

font2font.png


Last edited by MochiMoppel on Sat 27 Jun 2020, 03:17; edited 1 time in total
Back to top
View user's profile Send private message 
vovchik


Joined: 23 Oct 2006
Posts: 1538
Location: Ukraine

PostPosted: Fri 26 Jun 2020, 13:38    Post subject:  

Dear MochiMoppel,

Thanks. Very nicely done - and the comparison is useful.

With kind regards,
vovchik
Back to top
View user's profile Send private message 
greengeek


Joined: 20 Jul 2010
Posts: 5834
Location: Republic of Novo Zelande

PostPosted: Sat 27 Jun 2020, 03:03    Post subject:  

Useful utility, thanks.

Can you suggest why I see the following symbols shown when I compare Dingbats? I assume something must be missing from my system or incorrectly set up.

I can use Dingbats within Abiword so as far as I know the actual font is installed.

Thanks!
Compare_Dingbats.jpg
 Description   
 Filesize   63.39 KB
 Viewed   197 Time(s)

Compare_Dingbats.jpg

Back to top
View user's profile Send private message 
MochiMoppel


Joined: 26 Jan 2011
Posts: 2084
Location: Japan

PostPosted: Sat 27 Jun 2020, 05:24    Post subject:  

greengeek wrote:
I can use Dingbats within Abiword
No, you can not (assuming that you are still using Slacko 5.6).

You don't see numbers and letters in font2font because the Dingbats font doesn't contain these characters. It just contains (most) of the Unicode characters of the Dingbats block (hence the name Wink ) and a few other ornamental characters. When you open Abiword with a new document, select Dingbats as your font, then type away, what happens? Can you type any alphanumeric character? I can't. When I type Shift+% Abiword prints a telephone. And if you think that this is one of the few characters contained in the Dingbats font, you are wrong. What you see is a DejaVu Sans telephone, not a Dingbats telephone

Try to paste these 3 characters (click on "Edit sample text") into the font2font sample text: ☎✑✒
You can see that these characters are different in DejaVu Sans and Dingbats.

[Edit] Retracted my claim that no application renders Dingbats glyphs. Geany and Leafpad do. Abiword does too but only via the Insert > Symbols menu, where Dingbats font needs to be selected from the dropdown list.

.

Last edited by MochiMoppel on Mon 29 Jun 2020, 02:20; edited 3 times in total
Back to top
View user's profile Send private message 
greengeek


Joined: 20 Jul 2010
Posts: 5834
Location: Republic of Novo Zelande

PostPosted: Sat 27 Jun 2020, 16:20    Post subject:  

MochiMoppel wrote:
In fact you can't use the Dingbats font anywhere.
You don't see numbers and letters in font2font because the Dingbats font doesn't contain these characters. It just contains (most)
of the Unicode characters of the Dingbat Block ....
When you open Abiword with a new document, select Dingbats as your font, then type away, what happens? ...
When I type Shift+% Abiword prints a telephone. ...
Try to paste these 3 characters (click on "Edit sample text") into the font2font sample text: ☎✑✒ .
Oh my gosh. So many mysteries to be unravelled. Who knew this stuff was so complex? $%&*!??

Thanks for all the info. Much appreciated!
f2f_dings.jpg
 Description   
 Filesize   24.24 KB
 Viewed   122 Time(s)

f2f_dings.jpg

AbiwordDingbatTest.jpg
 Description   
 Filesize   31.79 KB
 Viewed   122 Time(s)

AbiwordDingbatTest.jpg

Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [5 Posts]  
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies. View previous topic :: View next topic
 Forum index » Off-Topic Area » Programming
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0421s ][ Queries: 13 (0.0107s) ][ GZIP on ]