community
community copied to clipboard
Backticks in strings are incorrectly handled in Kivy 2.1.0
This does not happen in the default font, but does in e.g. NotoSans. I initially thought it was creating accented characters, but on closer inspection it is simply offset.
import kivy
from kivy.app import App
from kivy.uix.button import Button
class ButtonApp(App):
def build(self):
btn = Button(text="`push` Me!",font_name="NotoSans-Regular.ttf")
return btn
root = ButtonApp()
root.run()
Kivy 2.0.0
Kivy 2.1.0
My current workaround is to simply use ' instead of ` for quoting
@sanderland , I am unable to reproduce the error
Button(text="`Test`")
Button(text="`Test`", font_name="CascadiaMonoPL-Regular.ttf")
Button(text="`Test`", font_name="NotoSans-Regular.ttf")
Button(text="`Test` Test", font_name="NotoSans-Regular.ttf")
Do you have this in the same directory as the app (or otherwise available?) NotoSans-Regular.zip
tried both ways, same result (global OS scope, and local program scope)
Problem happens for me: back ticks overlaying push Me!
Windows 11 SDL2 Kivy 2.2.1
It is a bug in the font: https://github.com/google/fonts/issues/3094
A new version is available, and when I used it the problem was fixed.
Closing as not Kivy's fault!