Re: Sinhala Font rendering incorrect in Kivy App

29 views
Skip to first unread message
Message has been deleted

Robert

unread,
Mar 4, 2023, 1:20:08 AM3/4/23
to Kivy users support
You have done the right thing by creating a GitHub issue https://github.com/kivy/kivy/issues/8148

Also bring up the issue on Discord was the right place as that is where the developers are most likely to see it.

The next best thing you can do is create a fork and PR that addresses your issue (these are GitHub terms).

Posting here will not be more effective. Sorry.

On Friday, March 3, 2023 at 6:49:16 PM UTC-10 ShanWick wrote:
Software Versions
  • Python: 3.10.9
  • OS: Windows, Android
  • Kivy: 2.1.0
  • Kivy installation method: pip install kivy

I rendered the following text with google Noto Sans Sinhala in kivy app and it is rendered incorrectly. Is Kivy able to render Sinhala characters correctly? As we want to support Sinhala languages ​​​​in our applications. Please help

Example text Expected output:
පාරිභෝගිකයා
2.png

Kivy application output:
Screenshot 2023-02-27 090231.png

This happens in all controls - label and text input and we have tried different ttf files.
Can we get some help here please?

Example code:
from kivy.app import App
from kivy.lang import Builder

kv = """
GridLayout:
id: layout
cols: 1
Label:
text: "Customer"
font_name: "NotoSansSinhala-Regular.ttf"
halign: "center"

"""

class Main(App):
def build(self):
return Builder.load_string(kv)

if name == "main":
main().run()

Font file link: https://fonts.google.com/noto/specimen/Noto+Sans+Sinhala

Elliot Garbus

unread,
Mar 4, 2023, 9:04:48 AM3/4/23
to kivy-...@googlegroups.com

 

From: ShanWick
Sent: Friday, March 3, 2023 9:49 PM
To: Kivy users support
Subject: [kivy-users] Sinhala Font rendering incorrect in Kivy App

 

Software Versions

  • Python: 3.10.9
  • OS: Windows, Android
  • Kivy: 2.1.0
  • Kivy installation method: pip install kivy


I rendered the following text with google Noto Sans Sinhala in kivy app and it is rendered incorrectly. Is Kivy able to render Sinhala characters correctly? As we want to support Sinhala languages ​​​​in our applications. Please help

Example text Expected output:
පාරිභෝගිකයා

 

Kivy application output:

 

This happens in all controls - label and text input and we have tried different ttf files.
Can we get some help here please?

Example code:
from kivy.app import App
from kivy.lang import Builder

kv = """
GridLayout:
id: layout
cols: 1
Label:
text: "Customer"
font_name: "NotoSansSinhala-Regular.ttf"
halign: "center"

"""

class Main(App):
def build(self):
return Builder.load_string(kv)

if name == "main":
main().run()

Font file link: https://fonts.google.com/noto/specimen/Noto+Sans+Sinhala

--
You received this message because you are subscribed to the Google Groups "Kivy users support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kivy-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kivy-users/fa061c0e-ff81-4598-9ef3-cedde00ace5cn%40googlegroups.com.

 

Screenshot 2023-02-27 090231.png
2.png
Reply all
Reply to author
Forward
0 new messages