Results 1 to 8 of 8
  1. #1
    Newbie
    Join Date
    Aug 2011
    Posts
    34
    Post Thanks / Like
    Rep Power
    0

    Default Question abour Skinning for plugin

    Hi i am writing a plugin for my Dreambox One UltraHD

    and plugin runs fine but my problem is that i get this error:

    AttributeError: 'eListbox' object has no attribute 'setFont'

    How do i add my custom font to the widget "menu"

    Here is the skin code and i have highlighted whats making my plugin crash
    If i remove this font="jediregular;36" then all works fine but i want my custom font in the menu




    <widget name="menu" position="519,309" size="892,672" font="jediregular;36" foregroundColor="#ffffff" backgroundColor="#000000"
    foregroundColorSelected="#ffffff" backgroundColorSelected="#000000" selectionPixmap="/usr/lib/enigma2/python/Plugins/Extensions/JediMakerXtream/skin/fhd/default/images/select-892-56.png"
    backgroundPixmap="/usr/lib/enigma2/python/Plugins/Extensions/JediMakerXtream/skin/fhd/default/images/blank.png"
    itemHeight="56" scrollbarMode="showOnDemand" transparent="1" zPosition="2" />

  2. #2
    Administrator deskjet's Avatar
    Join Date
    Jan 2014
    Location
    Calabria
    Posts
    1,910
    Post Thanks / Like
    Rep Power
    10

    Default Re: Question abour Skinning for plugin

    Which skin do you loop with? What is the plugin about?
    Dream-Elite Donation - Thanks for your support

    Dream Elite 7

  3. #3
    Newbie
    Join Date
    Aug 2011
    Posts
    34
    Post Thanks / Like
    Rep Power
    0

    Default Re: Question abour Skinning for plugin

    Plugin makes bouquets like Autobouquet maker

    and plugin in it self works just fine and do what it supose to do.
    But i am new to skinning for DreamOS and i have the main menu screen where i want to set my custom font
    But when i use font="jediregular;36" plugin crash with the error attributeerror: 'elistbox' object has no attribute 'setfont'
    So if i remove this code all works but now i have the regular font from Skin default instead of mine

    And its an embedded skin in the plugin i am not adding any screens to the Default skin

  4. #4
    Administrator deskjet's Avatar
    Join Date
    Jan 2014
    Location
    Calabria
    Posts
    1,910
    Post Thanks / Like
    Rep Power
    10

    Default Re: Question abour Skinning for plugin

    I'm sorry we can't help you with this.
    Dream-Elite Donation - Thanks for your support

    Dream Elite 7

  5. #5
    Newbie
    Join Date
    Aug 2011
    Posts
    34
    Post Thanks / Like
    Rep Power
    0

    Default Re: Question abour Skinning for plugin

    Accully i found out of it my self

    I hade to add this code to my menu.xml file in the plugin skinfolder

    <listboxcontent>
    <offset name="left" value="20" />
    <offset name="right" value="20" />
    <!-- used in a selection menus -->
    <font name="string" font="jediregular;36" />
    <value name="string_item_height" value="56" />
    <!-- used in a selection menu like setup screens -->
    <font name="config_description" font="jediregular;20" />
    <font name="config_value" font="jediregular;36" />
    <value name="config_item_height" value="57" />
    </listboxcontent>

  6. #6
    Administrator deskjet's Avatar
    Join Date
    Jan 2014
    Location
    Calabria
    Posts
    1,910
    Post Thanks / Like
    Rep Power
    10

    Default Re: Question abour Skinning for plugin

    Ok.Does it work on the Dream-Elite image?
    Dream-Elite Donation - Thanks for your support

    Dream Elite 7

  7. #7
    Newbie
    Join Date
    Aug 2011
    Posts
    34
    Post Thanks / Like
    Rep Power
    0

    Default Re: Question abour Skinning for plugin

    Yes it runs very nice on Dream Elite 7 and after some thinking to make the skin and plugin as compatible as possible
    I change my mind and now use the skin default font

  8. #8
    Newbie
    Join Date
    Aug 2011
    Posts
    34
    Post Thanks / Like
    Rep Power
    0

    Default Re: Question abour Skinning for plugin

    Well just as info i found a solution for this problem hidden in the nice code of Dream-Elite

    I could just add some applet code to my listbox and now all works really good

    <applet type="onLayoutFinish">
    from enigma import eListboxPythonConfigContent, gFont
    self["config"].l.setDescriptionFont(gFont("jediregular", 26))
    self["config"].l.setValueFont(gFont("jediregular", 26))
    self["config"].l.setItemHeight(36)
    </applet>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •