Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Packaging and running OurPaint and LaGUI #14

Open
FabioLolix opened this issue Jan 4, 2023 · 2 comments
Open

Packaging and running OurPaint and LaGUI #14

FabioLolix opened this issue Jan 4, 2023 · 2 comments

Comments

@FabioLolix
Copy link
Owner

Packaging and running OurPaint and LaGUI https://twitter.com/ChengduLittleA/status/1609921080923402241

  • Does exist a public development repository?

  • At first launch of OurPaint ~/preferences.udf is created, this should go in ~/.config/ourpaint (or ~/.config/OurPaint) (XDG stuff https://wiki.archlinux.org/title/XDG_Base_Directory)

  • LaGUI without fonts fails in package() step because there aren't the fonts


-- Installing: /home/fabio/Dev/Github/PKGBUILD-AUR_fix/zz_wip/lagui/pkg/lagui/usr/lib/lagui/lagui-config.cmake
CMake Error at cmake_install.cmake:96 (file):
  file INSTALL cannot find
  "/home/fabio/Dev/Github/PKGBUILD-AUR_fix/zz_wip/lagui/src/LaGUI/fonts/NotoEmoji-Regular.ttf":
  No such file or directory.

make: *** [Makefile:100: install] Errore 1
  • OnePaint can't find systems fonts, I have installed the noto-fonts packages in the official Arch repo noto-fonts, noto-fonts-cjk, noto-fonts-emoji, noto-fonts-extra. Didn't check on AUR
$ locate NotoSansCJK-Regular.ttc
/usr/share/fonts/noto-cjk/NotoSansCJK-Regular.ttc
$ LANG=C pacman -Qo /usr/share/fonts/noto-cjk/NotoSansCJK-Regular.ttc
/usr/share/fonts/noto-cjk/NotoSansCJK-Regular.ttc is owned by noto-fonts-cjk 20220126-1
$ locate NotoEmoji-Regular.ttf
<empty>
$ locate NotoSansSymbols-Regular.ttf
/usr/share/fonts/noto/NotoSansSymbols-Regular.ttf
$ LANG=C pacman -Qo /usr/share/fonts/noto/NotoSansSymbols-Regular.ttf
/usr/share/fonts/noto/NotoSansSymbols-Regular.ttf is owned by noto-fonts 20220810-1
$ locate NotoSansSymbols2-Regular.ttf
/usr/share/fonts/noto/NotoSansSymbols2-Regular.ttf
$ LANG=C pacman -Qo /usr/share/fonts/noto/NotoSansSymbols2-Regular.ttf
/usr/share/fonts/noto/NotoSansSymbols2-Regular.ttf is owned by noto-fonts 20220810-1
$ locate NotoSansMono-Regular.ttf
/usr/share/fonts/noto/NotoSansMono-Regular.ttf
$ LANG=C pacman -Qo /usr/share/fonts/noto/NotoSansMono-Regular.ttf
/usr/share/fonts/noto/NotoSansMono-Regular.ttf is owned by noto-fonts 20220810-1
  • LaGUI (with fonts) install them in ~.local/share/fonts/lagui/ this is not welcome in Arch packaging

  • OurPaint can't find one of the fonts even if it is installed in ~/.local/share/fonts/lagui/ and segfault

$ cd ~/.local/share/fonts/lagui
$ l
totale 21940
-rw-r--r-- 1 fabio fabio   878892  4 gen 01.05 NotoEmoji-Regular.ttf
-rw-r--r-- 1 fabio fabio 20332392  4 gen 01.05 NotoSansCJK-Regular.ttc
-rw-r--r-- 1 fabio fabio   383844  4 gen 01.05 NotoSansMono-Regular.ttf
-rw-r--r-- 1 fabio fabio   656820  4 gen 01.05 NotoSansSymbols2-Regular.ttf
-rw-r--r-- 1 fabio fabio   202972  4 gen 01.05 NotoSansSymbols-Regular.ttf
$ LANG=C OurPaint
Can't load font "NotoSansMono-Regular.ttf"
len lock 1
len hide 1
len blend_mode 1
len show_border 1
len color_interpretation 1
Errore di segmentazione (core dump creato)

Last line is "segmentation fault (core dump created)"

@ChengduLittleA
Copy link

Hi! I'm the author of Our Paint and LaGUI.

I sort of developed Our Paint for it to be portable so I packaged those fonts together with the program so if the appimage runs it will simply check its own directory. It's just so that fonts especially CJK ones are rather big and apparently a lot of systems doesn't come with that by default. The reason I didn't install those fonts into more "known" location in the system is because for some systems that has these fonts they might get overwritten and there are some differences with e.g ubuntu's cjk font file and the one acquired from google's site (I don't know the exact reason, but I suppose licensing and font variant localization plays a part), and to overwrite those system fonts might not be desired either. The fonts installed in .local/share/fonts/lagui are mostly for convenience of developing LaGUI programs, and those programs will be shipped later with font files directly packaged within. (LaGUI is a static lib, and users should not need to install LaGUI dev packages when they receive a LaGUI-based application)

Same with user preferences and brush files for portability. I think I can save a copy of preference inside .confg too. I did know XDG base directories so I think I can make it happen.

Does exist a public development repository?

I haven't quite set up a public repo yet, my web server is acting up on some of those stuff. Also the repo needs some additional cleaning. I'll notify here and on my page when public repo is okay to go.

OurPaint can't find one of the fonts even if it is installed in ~/.local/share/fonts/lagui/ and segfault

I found the issue. My font loading function for mono font didn't anticipate this path while regular font loading do. I'll fix this behaviour. LaGUI programs will search 11 different paths for these fonts, if you put the font directory simply adjacent to the executable it will find it.

@ChengduLittleA
Copy link

I have now updated stuff to my repositories, go check them out :D http://www.wellobserve.com/repositories/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants