LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 710|回复: 4

kde3无法开启字体渲染

[复制链接]
发表于 2008-7-29 09:34:05 | 显示全部楼层 |阅读模式
新装的opensuse11,kde3桌面,在外观-字体里面无法打开次像素渲染,选项被加灰了,已经看过置顶,并且也google过了,均无所获,故发帖求助,请了解的解答下,我是GMA900的集成显卡,还需要什么信息请指出,我也不知什么有用,或者别的地方有解决方法,给个链接也行
 楼主| 发表于 2008-7-29 12:47:01 | 显示全部楼层
问题已解决,在http://opensuse-community.org/Su ... 丁就可以了。  另外关于linux下的字体配置,有没有比较完整全面的文章来介绍的,我看到的都只说了一方面,不够系统
回复 支持 反对

使用道具 举报

发表于 2008-7-29 17:05:46 | 显示全部楼层
有没有效果对比图?

我装完了,怎么觉得没什么变化?
是不是我哪里没搞对?
回复 支持 反对

使用道具 举报

发表于 2008-7-29 18:17:14 | 显示全部楼层
这个补丁对qt4/gtk程序是无效的,还得另外给qt4和cairo打补丁
回复 支持 反对

使用道具 举报

发表于 2008-7-29 20:15:44 | 显示全部楼层
把local.conf放到/etc/fonts下试试

  1. # cat local.conf
  2. <?xml version="1.0"?>
  3. <!DOCTYPE fontconfig SYSTEM "fonts.dtd">
  4. <fontconfig>

  5. <!-- Generated by SuSEconfig.fonts, don't edit, your changes will get lost. -->
  6. <!-- Edit /etc/sysconfig/fonts-config instead.                              -->
  7. <!-- Or put rules into your personal config file ~/.fonts.conf.             -->

  8. <!-- ************************************************************ -->
  9. <!-- Hinting and antialiasing                                     -->
  10. <!-- ************************************************************ -->

  11.        <match target="pattern" >
  12.                <edit name="dpi" mode="assign" >
  13.                         <double>96</double>
  14.                 </edit>
  15.        </match>

  16. <!--
  17.     Using hinting=true, hintstyle=hintfull and antialias=true
  18.     is a good default for most fonts.

  19.     Match on "pattern" for the default, not on "font" to make
  20.     it easier to override the default using FcPatternDel()
  21.     and FcPatternAdd...() (see bugzilla #104365).
  22. -->

  23.         <match target="pattern">
  24.                 <edit name="hinting">
  25.                         <bool>true</bool>
  26.                 </edit>
  27.                 <edit name="hintstyle">
  28.                         <const>hintfull</const>
  29.                 </edit>
  30.                 <edit name="antialias">
  31.                         <bool>true</bool>
  32.                 </edit>
  33.         </match>

  34. <!--
  35.     Set autohinter=true as the default, then add exceptions for certain fonts.

  36.     Match on "font" here, not on "pattern" because of bug #118131 comment #93.
  37.     (If an autohint value is set in pattern, OpenOffice 2.1 will use that even
  38.     if there are fontconfig rules matching on "font" which should override it
  39.     again). This doesn't cause any problems for Cairo/Gnome (see bug #104365)
  40.     because Cairo/Gnome don't try to change the autohint value anyway.
  41. -->
  42.        
  43.         <match target="font">
  44.                 <edit name="autohint">
  45.                         <bool>true</bool>
  46.                 </edit>
  47.         </match>

  48.         <!--
  49.             Switch off the autohinter for PostScript fonts (Type 1 and OpenType CFF)
  50.             because using the PostScript hinting usually looks better than using
  51.             the autohinter.
  52.         -->

  53.         <match target="font">
  54.                 <test name="fontformat">
  55.                         <string>Type 1</string>
  56.                         <string>CFF</string>
  57.                 </test>
  58.                 <edit name="autohint">
  59.                         <bool>true</bool>
  60.                 </edit>
  61.         </match>

  62. <!--
  63.     TrueType Fonts which have high quality byte code interpreter
  64.     instructions can look very good in even in small sizes when using
  65.     the byte code interpreter (autohint=false). This is true
  66.     both with and without anti-aliasing.
  67.     In black and white (antialias=false) the results when rendering
  68.     with the byte code interpreter may even look as good as high quality
  69.     bitmap fonts.

  70.     On the other hand, some low quality TrueType Fonts do not have
  71.     byte code interpreter instructions at all or only very bad byte
  72.     code and may look better when the autohinter is used.
  73.     (See "FreeSans" for example, it looks better with the
  74.     autohinter which is especially obvious if anti-aliasing is off).
  75. -->

  76.         <!--
  77.             Switch off the autohinter for TrueType fonts in order
  78.             to use the byte code interpreter.
  79.         -->
  80.                
  81.         <match target="font">
  82.                 <test name="fontformat">
  83.                         <string>TrueType</string>
  84.                 </test>
  85.                 <edit name="autohint">
  86.                         <bool>true</bool>
  87.                 </edit>
  88.         </match>

  89.         <!--
  90.             Switch on the autohinter for a few TrueType fonts which
  91.             have no byte code or very bad byte code and look better
  92.             with the autohinter:

  93.             But see also bug #215602 for many fonts the autohinter
  94.             seriously distorts the metrics so badly that
  95.             even the digits which should be monospaced are not
  96.             monospaced at all anymore.

  97.             Because of this problem, better don't switch on
  98.             the autohinter for

  99.                Sazanami
  100.                IPA
  101.                DejaVu Sans Light
  102.                DejaVu Sans Condensed
  103.                DejaVu Serif Condensed
  104.                FreeSans
  105.                FreeSerif
  106.                FreeMono

  107.             and other fonts with similar problems until this is solved
  108.             in the autohinter.
  109.         -->

  110.         <match target="font">
  111.                 <test name="fontformat">
  112.                         <string>TrueType</string>
  113.                 </test>
  114.                 <test name="family">
  115.                         <string>Microsoft YaHei</string>
  116.                         <string>Vera Sans YuanTi</string>
  117.                         <string>Vera Sans YuanTi Mono</string>
  118.                         <string>MS PGothic</string>
  119.                         <string>MS UI Gothic</string>
  120.                         <string>MS Mincho</string>
  121.                         <string>MS PMincho</string>
  122.                         <string>HGPSoeiKakupoptai</string>
  123.                         <string>HGSGothicE</string>
  124.                         <string>HGSGothicM</string>
  125.                         <string>HGKyokashotai</string>
  126.                         <string>HGSSoeiKakugothicUB</string>
  127.                         <string>HGPGothicB</string>
  128.                         <string>HGPGothicE</string>
  129.                         <string>HGPGothicM</string>
  130.                         <string>HGSKyokashotai</string>
  131.                         <string>HGMaruGothicMPRO</string>
  132.                         <string>HGPSoeiKakugothicUB</string>
  133.                         <string>HGMinchoL</string>
  134.                         <string>HGPMinchoL</string>
  135.                         <string>HGMinchoB</string>
  136.                         <string>HGPMinchoB</string>
  137.                         <string>HGSMinchoB</string>
  138.                         <string>HGMinchoE</string>
  139.                         <string>HGPMinchoE</string>
  140.                         <string>HGSMinchoE</string>
  141.                         <string>HGSoeiKakugothicUB</string>
  142.                         <string>HGGyoshotai</string>
  143.                         <string>HGPGyoshotai</string>
  144.                         <string>HGSGyoshotai</string>
  145.                         <string>HGSoeiKakupoptai</string>
  146.                         <string>HGSSoeiPresenceEB</string>
  147.                         <string>HGPSoeiPresenceEB</string>
  148.                         <string>HGGothicB</string>
  149.                         <string>HGGothicE</string>
  150.                         <string>HGGothicM</string>
  151.                         <string>HGSoeiPresenceEB</string>
  152.                         <string>HGPKyokashotai</string>
  153.                         <string>HGSSoeiKakupoptai</string>
  154.                         <string>HGSeikaishotaiPRO</string>
  155.                         <string>TLKyokashotai</string>
  156.                         <string>TLMincho</string>
  157.                         <string>TLPMincho</string>
  158.                         <string>TLPGothic</string>
  159.                         <string>TLPKyokashotai</string>
  160.                         <string>TLMarugothicM</string>
  161.                         <string>TLGyoshotai</string>
  162.                         <string>TLPGyoshotai</string>
  163.                         <string>TLSGyoshotai</string>
  164.                         <string>TLPMarugothicM</string>
  165.                         <string>TLSMarugothicM</string>
  166.                         <string>TLSKyokashotai</string>
  167.                         <string>TLGothic</string>
  168.                 </test>
  169.                 <edit name="autohint">
  170.                         <bool>true</bool>
  171.                 </edit>
  172.         </match>


  173.         <!--
  174.             The following rule sets up black and white rendering with
  175.             the byte code interpreter for a small list of fonts which
  176.             are known to have good byte code and give bitmap quality
  177.             results at small sizes.
  178.             The pixelsize limit is set to '0' though, which effectively
  179.             disables this rule by default because most users don't like
  180.             that bitmap look and feel.
  181.             If you like a bitmap look and feel of your desktop,
  182.             copy this rule into your ~/.fonts.conf file and replace the '0'
  183.             with non-zero pixelsize limit. Using '18' as the pixelsize
  184.             limit is a good choice if you have the fonts in this list installed
  185.             and like a bitmap look and feel.
  186.         -->
  187.         <match target="font">
  188.                 <test name="family">
  189.                         <string>Microsoft YaHei</string>
  190.                         <string>Vera Sans YuanTi</string>
  191.                         <string>Vera Sans YuanTi Mono</string>
  192.                         <string>Andale Mono</string>
  193.                         <string>Arial</string>
  194.                         <string>Comic Sans MS</string>
  195.                         <string>Georgia</string>
  196.                         <string>Impact</string>
  197.                         <string>Trebuchet MS</string>
  198.                         <string>Verdana</string>
  199.                         <string>Courier New</string>
  200.                         <string>Times New Roman</string>
  201.                         <string>Tahoma</string>
  202.                         <string>Webdings</string>
  203.                         <string>Albany AMT</string>
  204.                         <string>Thorndale AMT</string>
  205.                         <string>Cumberland AMT</string>
  206.                         <string>Andale Sans</string>
  207.                         <string>Andy MT</string>
  208.                         <string>Bell MT</string>
  209.                         <string>Monotype Sorts</string>
  210.                 </test>
  211.                 <test name="pixelsize" compare="less_eq">
  212.                                 <double>0</double>
  213.                 </test>
  214.                 <edit name="autohint">
  215.                         <bool>true</bool>
  216.                 </edit>
  217.                 <edit name="antialias">
  218.                         <bool>true</bool>
  219.                 </edit>
  220.         </match>


  221. <!--
  222.   Some CJK fonts require the byte code interpreter to be rendered correctly.

  223.   These are composite fonts which store components and composing information
  224.   and compose the glyphs on the fly using the hinting instructions.

  225.   For all such fonts we switch off the autohinter here.
  226.   When "autohint" is set to "false", the byte code interpreter will
  227.   be used if it has been enabled at all when compiling freetype2.

  228.   The Chinese fonts "MingLiu" and "PMingLiU" used to belong to the fonts
  229.   which absolutely require the byte code interpreter to be rendered
  230.   correctly.
  231.   But apparently the new versions of "MingLiU" and "PMingLiU" from Windows
  232.   Vista are rendered correctly without the byte code interpreter.

  233. -->

  234.         <match target="font">
  235.                 <test name="family">
  236.                         <string>Microsoft YaHei</string>
  237.                         <string>MingLiU</string>
  238.                         <string>Vera Sans YuanTi</string>
  239.                         <string>Vera Sans YuanTi Mono</string>
  240.                         <string>PMingLiU</string>
  241.                 </test>
  242.                 <edit name="autohint">
  243.                         <bool>true</bool>
  244.                 </edit>
  245.         </match>

  246. <!--
  247. Hinting for CJK fonts in freetype doesn't yet work as well as for Latin fonts.

  248. Recently the autohinter in in freetype has been improved for CJK fonts
  249. a lot but it is still not perfect. Therefore one might want to switch
  250. off the autohinter for CJK fonts.

  251. This can be achieved by using the following rule:

  252.         <match target="font">
  253.                 <test name="lang" compare="contains">
  254.                         <string>ja</string>
  255.                         <string>zh</string>
  256.                         <string>ko</string>
  257.                 </test>
  258.                 <edit name="autohint">
  259.                         <bool>true</bool>
  260.                 </edit>
  261.         </match>
  262. -->

  263. <!--
  264. for some Bengali fonts (e.g. "Mukti Narrow"), the autohinter works well
  265. with the patch from http://www.kde.gr.jp/~akito/patch/freetype2/2.1.7
  266. applied. But for "Likhan" it still doesn't work that well
  267. (look how the "matra" lines at the top line up). Therefore, switch
  268. off the autohinter for the "Likhan" font:
  269. -->

  270.         <match target="font">
  271.                 <test name="family">
  272.                         <string>Likhan</string>
  273.                         <string>Microsoft YaHei</string>
  274.                         <string>Vera Sans YuanTi</string>
  275.                         <string>Vera Sans YuanTi Mono</string>
  276.                 </test>
  277.                 <edit name="autohint">
  278.                         <bool>true</bool>
  279.                 </edit>
  280.         </match>


  281. </fontconfig>
复制代码
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表