2023-08-21, 02:32
Is there a way to make the xbmcgui.ControlLabel wordwrap within the set width? Currently, when the label gets to the end of the "width" with more text to display, it just puts three dots and moves to the next paragraph.
CURRENT CODE:
def display_description(self, description_text):
# Create a Kodi label control with the provided description text
description_label = xbmcgui.ControlLabel(
x=self.button_width + 100,
y=self.button_height + 100,
width=self.screen_width - (self.button_width + 150),
height=self.button_height + (self.button_vert_gap*2), # Adjust the height as needed
label=description_text,
font="font13",
textColor="FFFFFFFF", # White text color
alignment=1
)
# Add the description label control to the Kodi window
self.parent_window.addControl(description_label)
CURRENT CODE:
def display_description(self, description_text):
# Create a Kodi label control with the provided description text
description_label = xbmcgui.ControlLabel(
x=self.button_width + 100,
y=self.button_height + 100,
width=self.screen_width - (self.button_width + 150),
height=self.button_height + (self.button_vert_gap*2), # Adjust the height as needed
label=description_text,
font="font13",
textColor="FFFFFFFF", # White text color
alignment=1
)
# Add the description label control to the Kodi window
self.parent_window.addControl(description_label)