Tiny Core Linux
Tiny Core Base => TCB Q&A Forum => Topic started by: mbertrand on August 03, 2012, 10:50:18 AM
-
I'm deploying QT apps built on Ubuntu to Tiny Core. How do I add, configure fonts in Tiny Core?
-
Add is simply copy them to the correct dir (/usr/local/share/fonts or /usr/share/fonts for system wide, ~/.fonts for per-user).
Configure, that depends on what you want. Fontconfig config files are under /etc, the anti-aliasing, preference, subpixel etc settings are set there. I don't recall the per-user location for those, but that exists too.
-
I know QT uses Fontconfig. Would just copying them to usr/share/fonts would allow QT to see them are I need to do more.
I'm not familiar with fontconfig.
-
Just copying is enough to add fonts.
-
See also:
http://forum.tinycorelinux.net/index.php/topic,8262.0.html
-
Not working. Here is my test. I created a form in designer with a label only on it using lets say font "Arial" On my Ubuntu machine.
I copied this font to my Tiny Core in /usr/share/fonts. When I run my program on Tiny Core it is not using that font.
Another try was to use QT QFontCombo witch lists all font it knows about in your system. This does not list my "Arial" that I copied.
-
Have you read the thread I linked to?
-
Yes, I'm not using Opera but understand the thread. This did not help me. I did install fontconfig at the very begining.
I don't know how to use it. I will look in to it.
-
I installed Opera for fun to see and it lists the fonts I copied. So what I'm doing wrong.
Opera is listing different fonts then My QT test app. My test app has fonts I don't even know like:
Fixed[Misc]
Fixed[Sony]
Helvitica
Nil
And Opera is listing font that I've actually herd of like:
Arail
Courier New
Times New Roman
I'm LOST !!!
-
Well it seems what ever font I copy Opera sees it but not my QT app. Maybe something additional as to be done???
-
Hmm, I had hoped your app would behave in the same way as opera...
Obviously not :(
-
Why is your qt app only using bitmap fonts? What Qt are you using?
-
Oh is that what it is doing I didn't know this. See these fonts that I've listed in the previous post are bitmap fonts?
-
Yes, and once opera is picking up the fonts you added you can exclude any systemwide issue.
-
I'm confused here , does Tiny Core support TTF?
I'm trying to educate my self regarding fonts but there a vast earea to cover!!
I got Tiny Core, X, QT, Fontconfig ect.to look at. Do you know of any good links I can start?
-
Yes, TC obviously supports TTF fonts ;) But it sounds like your Qt doesn't. You didn't answer on what Qt you're using.
-
I'm using QT 4.8.2
-
Could I be missing extension. This is what I have now:
Xlibs.tcz
Xorg-7.5-lib.tcz
Xorg-7.6-lib.tcz
Xprogs.tcz
fltk-1.10.tcz
flwm_topside.tcz
gcc_libs.tcz
libftdi.tcz
libpci.tcz
libusb.tcz
openssh.tcz
openssl-1.0.0.tcz
pci-utils.tcz
usb-serial-3.0.21-tinycore.tcz
usb-utils.tcz
wbar.tcz
xvtouch.tcz
Xvesa.tcz
x11vnc.tcz
nano.tcz
udev-lib.tcz
fontconfig.tcz
opera-11.tcz
Xorg-fonts.tcz
Xorg-7.6-bin.tcz
-
I'd suspect that libxft would be a dep of any of those, but not sure.
For testing purposes I'd suggest you use opera10 which AFAIK is the only version in repo depending on shared qt libs - opera11 is no longer qt based.
-
No, I mean what Qt as in where it comes from, not the version. Is it from our repo, or copied from Ubuntu, or linked statically, or some other way.
Clearly not from our repo, seeing as the version is different.
-
It is a dynamic built by me from their source (4.8.2)on my Ubuntu and deployed to my Tiny Core.
I download from your repos QT Designer 4.7.4 just to see how it will list its available fonts and it has no problem.
My Test program on Ubuntu does not list all the fonts that Designer does. I'm really lost now!!
-
That sounds like an issue with your Qt code, then. Maybe ask at a Qt forum?
-
Not my code. It does nothing it is a QWindow with a QFontComboBox.
I just stomped on something here, I'm building on my Ubuntu with 4.8.2 and using libs from your repos at 4.7.4.
I built with 4.7.4 and all is well!!! I looks maybe like something is not backwards compatible regarding QT? This looks now more like
a QT problem and therefore I will not bombarded you with question not related to Tiny Core. I appreciate you time and thanks.
I let you you know my final outcome, maybe some else may one day have the same problem.
-
Oh, that's not even supposed to work :) (compiling against a newer version than you're running with)
-
QT has good backward compatibility but to some extent! My app compiled against 4.8.2 will run with 4.7.4 libs.
This was not my plan. Anyways it looks like QT's 4.8.1 build works and 4.8.2 does not.
The 4.8.1 is a built I got directly from QT. The build 4.8.2 is a built I did. So, either something is wrong with my build or their source. I'm investigating.
-
Well, it turns out to be my build of QT libraries, Why, don't know as of now but for now I'm using pre built from QT and al work well.
But I would like to know what fonts come with Tiny Core and where are they.
-
You could compile under core instead of ubuntu to see if that makes any difference.
-
Ok, I found the problem It was as a mentioned my build of QT libs. QT libs need to be built with fonconfig support.
By default it is but if you don't have the fonconfig development lib on your build system QT lib still builds with no warning, at least I did not see any obvious warnings. So I ended up with a built lib and no fontconfig support.
Thanks for all your support.
Keep the great work.
-
I wouldn't expect a warning when libs for an optional feature are not installed - at best an information of optional features included at the end of output of ./configure.
I'd reckon if you examine the output of ./configure such would be visible.
However, feel free to make suggestions of improvement with upstream. ;)