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

Add legacy font titles to Font.xml for backwards compatibility #472

Closed
wants to merge 1 commit into from

Conversation

petroid
Copy link

@petroid petroid commented Jan 1, 2024

Some addons such as Digital Clock Screensaver by vdb86 use fonts named with legacy font naming scheme ("Large", "Small" etc.) Also there are no large enough fonts to use for fullscreen clock. See vdb86/screensaver.digitalclock#60
I propose adding legacy font titles to font.xml for backwards compatibility.

@Ch1llb0
Copy link
Contributor

Ch1llb0 commented Jan 1, 2024

I'm not sure I'm fully understanding... Which legacy font style would that be - a Kodi legacy font style? And why do we need to add specific font styles to the skin (the skin own fonts are only meant for the skin, not any addons)? And lastly, why add legacy fonts for addons that simply should not do things like this nowadays?

It might be ignorance, but that's the questions that come to my mind, so I'll ask openly 😊

@petroid
Copy link
Author

petroid commented Jan 2, 2024

As far as I understand, addons such as screensavers are bound to use whatever fonts are defined in font.xml of Kodi skin.
Previously in OSMC skin fonts were defined with names such as "Large", "Small" etc. and addons were using these names. Also there was huge font (size 120) which was used for things like fullscreen clock (for instance, in Estuary skin it is still present under name "WeatherTemp"). Now that fonts' names are different and there is no font in OSMC skin that is large enough these addons no longer look as they supposed to.
Maybe I am missing something in the way Kodi skins are working. If there is a way nowadays for addons such as Digital Clock Screensaver to define and use their own fonts please point me in that direction.
Thanks!

@Ch1llb0
Copy link
Contributor

Ch1llb0 commented Jan 3, 2024

I honestly don't know at all... I'm just baffled by the system that would prevent addons that need fonts from defining them themselves and at the same time forcing skinners to add fonts to their skins that they don't need. I've cleaned up our skin code to get rid of things the skin doesn't need - I wasn't even aware any other addon might use some of that code.
Will investigate and see what can be done. If there's no other way, I can add back a font specific to one external addon, but I'm honestly not happy about this.

@petroid
Copy link
Author

petroid commented Jan 3, 2024

Kodi skinning and addon development documentation does not make it clear if script type screensaver addons (such as Digital Clock) could define their own fonts. I spent whole day digging into it and still not sure. At least there is no examples I'm aware of.
I figured out that many skins including Kodi default (Estuary) have font "WeatherTemp" defined. That one font in OSMC skin would be enough for Digital Clock to look as it should and might also improve compatibility with another script addons that were developed with default skin in mind and use that font. Not that I'm aware of any such addons except Digital Clock.
I would not be very happy about adding something to my code that I don't use too and if you decide not to do it I'll understand.

@Ch1llb0
Copy link
Contributor

Ch1llb0 commented Jan 4, 2024

Addressed with: 863d92c

@Ch1llb0 Ch1llb0 closed this Jan 4, 2024
@petroid petroid deleted the patch-1 branch January 4, 2024 21:54
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

Successfully merging this pull request may close these issues.

2 participants