Open justvanrossum opened 4 years ago
It gets messy since variable fonts are bound to have unique lists of named instances.
"Reset all axes to default" is still important, though.
A "Reset all axes" button has been implemented since v0.9.8.
(Came here when trying to suggest this feature ;) )
I could see those living in the Variations tab, as dropdown above or below the axes. The reset axes button is already super useful, thanks!
I also was preparing to suggest this, and let me also add my thanks.
Came back still wanting for this so I dug a bit into the code seeing if I could hack it myself... @justvanrossum could you give me a few pointers with first steps to get started?
python App/setup.py py2app && open App/dist/FontGoggles.app
I get the app running, but I cannot seem to open any fonts — is there some mac security getting in the way here?-A
option, I suppose that's the best way to quickly preview changeslogging
will forward to the Console on Mac, for checking what's going on in the app while I figure out how to add the actual feature codemainWindow.py
use the variationsGroup
but make it a Group that has the sliders + a PopUpButton
for the instances of all open VF — new to Vanilla... does that sound about right, technically, and logically for a placement of such a feature?Appreciate any help :)
(maybe related or not to not being able to open fonts, when starting up, these errors appear in the Console:
error 22:16:03.239711+0200 FontGoggles open flag(s) 0x01000000 are reserved for VFS use and do not affect behaviour when passed to sqlite3_open_v2
error 22:16:03.240112+0200 FontGoggles cannot open file at line 46922 of [6bf7a27121]
error 22:16:03.240155+0200 FontGoggles os_unix.c:46922: (2) open(/private/var/db/DetachedSignatures) - No such file or directory
any idea where such sqlite / file access originates from?
You can start the app from Terminal like so:
./App/dist/FontGoggles.app/Contents/MacOS/FontGoggles
This gives you all (debug) output right in Terminal, without having to bother with Console.
I don't understand that sqlite message: FontGoggles doesn't use sqlite.
Yes, I agree that a popup for named instances makes most sense as part of the Variations tab.
I'm still doubtful about the overall UI for this, given FontGoggle's ability to show multiple fonts simultaneously, and generally shows the superset of features/variations/etc available to all fonts shown. I fear the list of named instances will become messy when looking at multiple variable fonts.
An alternative may be to treat named instances like fonts in a collections (TTC). For example, we could add a contextual menu named "Expand named instances", and it would add all named instances as individual "fonts".
Thanks, I agree on the potential overflow of instance names; imo this is related to another issue requesting the axes should be split by font. Maybe a refactor of those will go hand in hand... for now I'd just like to get some instances. :) It could also be one instances-dropdown per VF loaded.
Do you have any idea why I am unable to open any font files with the built app, is that something you have encountered? I'll try debug the font loading code with the direct opening from the Contents
to see if I can find the reason.
Do you have any idea why I am unable to open any font files with the built app, is that something you have encountered?
No clue unfortunately. Does it output anything meaningful to Terminal when you run FG the way I described?
Tried fresh environment, but nope.
Build trace seems okay, nothing jumping out here:
Executing task: python App/setup.py py2app -A && ./App/dist/FontGoggles.app/Contents/MacOS/FontGoggles
Hello .zprofile
/Users/johannes/Projects/fontgoggles/App/setup.py:2: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
import pkg_resources
running py2app
creating /Users/johannes/Projects/fontgoggles/App/build/bdist.macosx-14.4-arm64/python3.12-standalone/app
creating /Users/johannes/Projects/fontgoggles/App/build/bdist.macosx-14.4-arm64/python3.12-standalone/app/collect
creating /Users/johannes/Projects/fontgoggles/App/build/bdist.macosx-14.4-arm64/python3.12-standalone/app/temp
creating build/bdist.macosx-14.4-arm64/python3.12-standalone/app/lib-dynload
creating build/bdist.macosx-14.4-arm64/python3.12-standalone/app/Frameworks
Add paths for VENV /Users/johannes/.pyenv/versions/3.12.2 False
*** creating application bundle: FontGoggles ***
Copy '/Users/johannes/.pyenv/versions/fontgoggles/lib/python3.12/site-packages/py2app/apptemplate/prebuilt/main-arm64' -> '/Users/johannes/Projects/fontgoggles/App/dist/FontGoggles.app/Contents/MacOS/FontGoggles'
sign ['/Users/johannes/Projects/fontgoggles/App/dist/FontGoggles.app/Contents/MacOS/FontGoggles']
/Users/johannes/Projects/fontgoggles/App/dist/FontGoggles.app/Contents/MacOS/FontGoggles: replacing existing signature
/Users/johannes/Projects/fontgoggles/App/dist/FontGoggles.app/Contents/MacOS/FontGoggles: signed app bundle with Mach-O thin (arm64) [com.github.justvanrossum.FontGoggles]
/Users/johannes/Projects/fontgoggles/App/dist/FontGoggles.app: replacing existing signature
/Users/johannes/Projects/fontgoggles/App/dist/FontGoggles.app: signed app bundle with Mach-O thin (arm64) [com.github.justvanrossum.FontGoggles]
Done!
/Users/johannes/Projects/fontgoggles/App/FontGoggles.py:11: DeprecationWarning: Set objc.options.verbose instead
objc.setVerbose(True)
The app does build and launch, and e.g. the About menu or the Font open dialog work, just nothing happens after that. Peculiar... I try see if I can debug any more.
Shouldn't make a difference, but can you try py2app without -A
?
Also: a way to go back the default axis value for all fonts.
(To not have per-font settings is a little confusing here.)