Created
June 11, 2021 12:29
-
-
Save kengoon/9766ef6be656f97334fa8ae616f799f0 to your computer and use it in GitHub Desktop.
example of how to use icofont
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
from kivymd.app import MDApp | |
from kivy.lang import Builder | |
from kivymd.uix.label import MDIcon, MDLabel | |
from kivymd.uix.button import MDIconButton | |
from tools.iconfonts import icon, register | |
register("material", "fonts/MaterialIconsSharp-Regular.otf", "fonts/MaterialIconsSharp-Regular.fontd") | |
class Test(MDApp): | |
def build(self): | |
Ic = MDIcon(halign="center", markup=True, font_style="Icon") | |
Ic.text = icon("search", font_name="material") | |
return Ic | |
Test().run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment