mirror of
https://github.com/aclist/dztui.git
synced 2026-11-06 18:10:58 +01:00
feat: embolden func
This commit is contained in:
1 parent
c4b918d61e
commit
72c1081b48
5 files changed
+23
-12
No files matched your search
@@ -1,3 +1,4 @@
|
||||
from dzgui.util.format import embolden
|
||||
from dzgui.views.components.web_button import WebButton
|
||||
|
||||
import gi
|
||||
@@ -12,10 +13,9 @@ class ConnectPanel(Gtk.Frame):
|
||||
self.label = Gtk.Label(label="Add/connect")
|
||||
self.label2 = Gtk.Label(label="Favorite server")
|
||||
|
||||
# TODO: embold function
|
||||
#self.label2.set_markup("<b>Favorite server</b>")
|
||||
|
||||
self.label2.set_markup("<b>Favorite server</b>")
|
||||
# TODO: strings
|
||||
text = embolden("Favorite server")
|
||||
self.label2.set_markup(text)
|
||||
self.entry1 = Gtk.Entry(placeholder_text="Enter IP or Battlemetrics ID", hexpand=False)
|
||||
self.entry2 = Gtk.Entry()
|
||||
self.fav = Gtk.Label(label="MY favorite server very long title")
|
||||
|
||||
@@ -2,7 +2,8 @@ from typing import TYPE_CHECKING
|
||||
|
||||
from dzgui.const.enum import ModButton
|
||||
from dzgui.const.constants import NO_EXPAND, FILL
|
||||
from dzgui.util import strings
|
||||
from dzgui.util.strings import mod_panel
|
||||
from dzgui.util.format import embolden
|
||||
|
||||
import gi
|
||||
gi.require_version("Gtk", "3.0")
|
||||
@@ -34,7 +35,8 @@ class ModSelectionPanel(Gtk.Box):
|
||||
)
|
||||
|
||||
self.header = Gtk.Label()
|
||||
self.header.set_markup(f"<b>{strings.mod_panel.header}</b>")
|
||||
text = embolden(mod_panel.header)
|
||||
self.header.set_markup(text)
|
||||
|
||||
self.main_panel = Gtk.Box(orientation=Gtk.Orientation.VERTICAL, spacing=6)
|
||||
for button in buttons:
|
||||
|
||||
Reference in new issue
Block a user