liushaolin / gdipp

Automatically exported from code.google.com/p/gdipp
0 stars 0 forks source link

Individual font-specific nodes not working in settings.xml #91

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
Enter font-specific settings, restart the gdipp service and see the individual 
settings not applied.

What version of gdipp (including renderer)? On which operating system?
0.8.1, Freetype Renderer (10), Windows 7 x64 Home Premium

Please provide any additional information below. Screenshots always help.

I read the Settings page on the wiki over and over again, but can't seem to 
figure out how this font-specific settings should be placed in the settings xml 
file. I'm not sure if I'm doing something wrong or it's gdipp's fault.

When first installing there are the <process name=".+\.exe"> and 
<font name=".+"> nodes inside the <gdimm> node, and no matter where I place the 
font-specific nodes such as <font name="Segoe UI.*"> before or after the 
default (global) settings node, it does not get take effect.

Please Help!

Original issue reported on code.google.com by kim...@gmail.com on 19 Jul 2010 at 7:29

GoogleCodeExporter commented 8 years ago
Sorry for delayed answer. Google Code is under maintenance for long time, and I 
cannot make reply.

To correctly write the setting file, make sure all "process" nodes come BEFORE 
any "font" node. This guarantees process-specific settings are adopted first. 
Also, "freetype" node can be only put inside a "process" node.

The "font" node with name ".+\.exe" should be the last of the "font" nodes. If 
you need font-specific setting, put <font name="Segoe UI.*> between the last 
"process" node and the last "font" node.

If you did so, and the setting is not applied, there is something wrong. You'd 
better upload your setting file and let me examine for you.

Original comment by crendk...@gmail.com on 8 Aug 2010 at 12:04

GoogleCodeExporter commented 8 years ago
I just tried putting the <font name" > inbetween the last process node and the 
<font name=".+"> as you said, but doesn't seem to work. Tried changing both 
embolden and renderer (since they're the most obvious when changed) values, 
saved the file (with administrator privilege) and reloaded notepad/firefox, and 
nothing's changed.

I'll paste my code here so you might want to take a look.

Original comment by kim...@gmail.com on 9 Aug 2010 at 8:11

Attachments:

GoogleCodeExporter commented 8 years ago
Confirming on 0.9.1, FreeType renderer (10), Windows 7 Ultimate 32-bit.
I tried matching MS PGothic with various regexp, including "MS.*Gothic.*","MS 
.?Gothic.*","MS PGothic.*",".*ゴシック.*", etc.

I inserted it between program and main font matcher.

------->
        <cache_max_bytes>1048576</cache_max_bytes>
        <lcd_filter>1</lcd_filter>
    </freetype>
</process>
<font name="MS.*Gothic.*">
    <embolden>-24</embolden>
</font>
<font max_height="72">
    <auto_hinting>1</auto_hinting>
    <embedded_bitmap>0</embedded_bitmap>
    <embolden>0</embolden>
<!-------

I've tried it with various positions: right after </process>, after first 
</font>, after last </font>.
Next, I'll probably do a regression check with older versions.

Original comment by syoc...@gmail.com on 15 Mar 2011 at 12:35

GoogleCodeExporter commented 8 years ago
Woops, I tried reinstalling with clean slate (deleted gdipp after previous 
uninstall) and I find that I can match MS Gothic by using ".*ゴシック.*".

Kimatg, can you try using native name? Like
<font name=".*돋움.*">

Original comment by syoc...@gmail.com on 15 Mar 2011 at 1:55