Menu

#47 Optional XFT support

open
nobody
UI (9)
5
2019-04-23
2012-05-11
realturner
No

I've coped to deal with the patching and compiling issues of the old XFT patch.
Everything goes fine if I didn't set USE_XFT=1 in system.mk.
And all the compilation works fine even when USE_XFT=1 is set.

But when I tried to run the executable, the wm didn't show up.
The log says de.so cannot find symbol `XftFontOpenName', which is already in the /usr/lib/libXft.so

Attached is the XFT patch, just worked as of now (Sat May 12 00:07:13 CST 2012),
but with the runtime problem mentioned.

I think some of the build system might changed since the patch worked at 2011-08-27.
Since I am unable to handle it by myself anymore, can I expect this option be merged?

Discussion

  • realturner

    realturner - 2012-05-11

    Notion Xft Option Patch

     
  • Arnout Engelen

    Arnout Engelen - 2012-05-11

    I'm not sure what caused your runtime problem.

    About the patch:
    - it seems fairly concentrated, only modifying stuff in 'de/*' and the build procedure
    - indentation is not consistent with the notion style (indentations in the patch are sometimes 8 spaces instead of 4)
    - '#ifndef / #else / #endif is used a lot - this is kind of a double negation, I'd prefer '#ifdef / #else / #endif'

    If those are fixed I guess we could at least consider that patch (keeping the default to disable XFT)

     
  • realturner

    realturner - 2012-05-12

    Thanks for your reply

    I am not the original contributor, so I don't actually knows how this patch works.
    All I have done is fixing the compiling problem from the original one.

    I figured out the .so problem and did a fix in de/Makefile.
    Without setting the LIBS variable in the Makefile, libXft.so won't be considered a dependency for de.so.
    Now the patch should work again, with disabling XFT by default.

    It seems like only the `de' module requires libxft.
    If it's impossible of other modules using it, maybe we can just modify the CFLAGS for the de module but not the whole system.mk.

    There is a tabbar-styling issue: when enabling XFT, de won't draw tabbar color style correctly before it is focused once.
    Since it isn't that bothering me than unable to display unicode characters, I just let it go.
    Maybe one day I will fix it?

    If the previously mentioned styling issue doesn't matter, will you consider this patch?

     
  • Arnout Engelen

    Arnout Engelen - 2012-05-12

    I wonder if it'd be better to have this as a compile-time option or a startup option. http://permalink.gmane.org/gmane.comp.window-managers.ion.general/3193 suggests there should be a version of the patch with runtime configurability. I don't find this in the notion history though: it seems compiletime switching of xft was removed in commits f6f739298d1abfa9354e7b9dbaa8e339ed4fcfee and ed0eda37faaf01e2aa0c860c779e2442e6af8b38.

    Xft seems controversial. I'd be interested in hearing arguments for and against including support for it. You mention properly displaying unicode characters - is this impossible without Xft?

     
  • realturner

    realturner - 2012-05-12

    If displaying unicode characters (CJK chars in my case) works without Xft, I don't mind removing Xft support.
    In fact, I use Xft because it displays my pcf bitmap font properly, while the original one fails and I don't know why.
    It looks like there is already unicode support in notion, but my pcf font (wenquanyi_9pt.pcf) fails to work properly.
    If there's a way to get rid of my problem, I personally would agree to not using Xft.

     
  • Arnout Engelen

    Arnout Engelen - 2012-05-12

    Some more information on how i3 handles xft: http://comments.gmane.org/gmane.comp.window-managers.i3.general/176

    I've made a seperate issue about unicode support. I'd love it if you could help me reproduce the kind of problems you're having with it.

     
  • Campbell Barton

    Campbell Barton - 2014-04-09

    Updated the patch:

    • consistent indentation
    • makefile added -D define to the include var, changed this.

    http://www.graphicall.org/ftp/ideasman42/notion-xft_v2.diff

     
  • Campbell Barton

    Campbell Barton - 2014-04-09

    Attached patch

     

Anonymous
Anonymous

Add attachments
Cancel