Hello Guest, if you are reading this it means you have not registered yet. Please take a second, Click here to register, and in a few simple steps you will be able to enjoy our community and use our OpenViX support section.
Page 10 of 12 FirstFirst ... 89101112 LastLast
Results 136 to 150 of 179

Thread: New skin: Simple Ten Eighty

  1. #136
    Huevos's Avatar
    Title
    Administrator
    Join Date
    Jun 2010
    Location
    38.5N, 0.5W
    Posts
    13,581
    Thanks
    2,004
    Thanked 4,925 Times in 3,259 Posts


    This is what I see.

    1.jpg
    Help keep OpenViX servers online.Please donate!

  2. #137
    ccs's Avatar
    Title
    ViX Beta Tester
    Join Date
    Sep 2014
    Posts
    5,836
    Thanks
    554
    Thanked 1,276 Times in 1,089 Posts
    .... but you've recently changed it .....

    Code:
    https://github.com/OpenViX/skins/commit/f85ce61ac6b15cd1dbb709f30fa17cc21a90882d
    "Today", top leftish, fits, but the following days don't, and it's repeated a few lines above anyway.

    I've got "service width" set to the absolute minimum, to maximise the programme title widths.

    Will the programme description be optional in the new version?
    Last edited by ccs; 07-04-21 at 18:55.

  3. #138
    ccs's Avatar
    Title
    ViX Beta Tester
    Join Date
    Sep 2014
    Posts
    5,836
    Thanks
    554
    Thanked 1,276 Times in 1,089 Posts
    Workaround (of sorts, with my settings): Set "Alignment of timeline date" to "left, wrapped", rather than using the default (the right hand attachment).
    Attached Images Attached Images
    Last edited by ccs; 07-04-21 at 19:34.

  4. #139
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by ccs View Post
    Workaround (of sorts, with my settings): Set "Alignment of timeline date" to "left, wrapped", rather than using the default (the right hand attachment).
    Which would appear to work only by allowing the year to wrap onto the next line in a one-line box, where it disappears.
    Doesn't sound like a real solution.
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  5. #140
    ccs's Avatar
    Title
    ViX Beta Tester
    Join Date
    Sep 2014
    Posts
    5,836
    Thanks
    554
    Thanked 1,276 Times in 1,089 Posts
    Quote Originally Posted by birdman View Post
    Doesn't sound like a real solution.
    Based on the replies I've already had, it'll have to do, real or not.

  6. #141
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by ccs View Post
    Based on the replies I've already had, it'll have to do, real or not.

    Or you could change the serviceWidth check in setEntries (in Components/EpgListGrid.py) since they appear to be wrong. Or at leats the logic is wrong. You really need to get each of the three possible date formats (starting with the longest) and stop once what you have fits within serviceWidth. The current code is juts a piece of guesswork, as you have no idea what font size is being used for the display.
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  7. #142
    Huevos's Avatar
    Title
    Administrator
    Join Date
    Jun 2010
    Location
    38.5N, 0.5W
    Posts
    13,581
    Thanks
    2,004
    Thanked 4,925 Times in 3,259 Posts
    What you are suggesting would only be possible with a fixed width font.
    Help keep OpenViX servers online.Please donate!

  8. #143
    ccs's Avatar
    Title
    ViX Beta Tester
    Join Date
    Sep 2014
    Posts
    5,836
    Thanks
    554
    Thanked 1,276 Times in 1,089 Posts
    Line 927 of Components/EpgListGrid.py looks like this

    Code:
    			fnum = float(timeEpoch)/float(timeSteps)
    			incWidth = int(eventRect.width() / fnum)
    			timeStepsCalc = timeSteps * SECS_IN_MIN
    
    			nowTime = localtime(time())
    			begTime = localtime(timeBase)
    			serviceWidth = serviceRect.width()
    			if nowTime.tm_year == begTime.tm_year and nowTime.tm_yday == begTime.tm_yday:
    				datestr = _("Today")
    			else:
    				if serviceWidth > 179:
    					dateFormat = config.usage.date.daylong.value
    				elif serviceWidth > 129:
    					dateFormat = config.usage.date.dayshort.value
    				elif serviceWidth > 79:
    					dateFormat = config.usage.date.daysmall.value
    				else:
    					dateFormat = "%a"
    				datestr = strftime(dateFormat, begTime)
    I've got Service width in the grid epg set to 225, and the date "Fri 9 Apr 2020" doesn't fit.

    If I mess with EpgListGrid.py and force the date to be "Fri 9 Apr", it fits ok....

    Code:
    			fnum = float(timeEpoch)/float(timeSteps)
    			incWidth = int(eventRect.width() / fnum)
    			timeStepsCalc = timeSteps * SECS_IN_MIN
    
    			nowTime = localtime(time())
    			begTime = localtime(timeBase)
    			serviceWidth = serviceRect.width()
    			if nowTime.tm_year == begTime.tm_year and nowTime.tm_yday == begTime.tm_yday:
    				datestr = _("Today")
    			else:
    				if serviceWidth > 999:
    					dateFormat = config.usage.date.daylong.value
    				elif serviceWidth > 2:
    					dateFormat = config.usage.date.dayshort.value
    				elif serviceWidth > 1:
    					dateFormat = config.usage.date.daysmall.value
    				else:
    					dateFormat = "%a"
    				datestr = strftime(dateFormat, begTime)
    EDIT: If I make the Timeline font size small enough I should be able to see when the date format changes for different service widths.

    Service width of 173 changes the date format (loses the year), Timeline font size -2.
    Last edited by ccs; 08-04-21 at 11:11.

  9. #144
    ccs's Avatar
    Title
    ViX Beta Tester
    Join Date
    Sep 2014
    Posts
    5,836
    Thanks
    554
    Thanked 1,276 Times in 1,089 Posts
    For my Service width of 225, Line 937 of EpgListGrid.py, when set to "if serviceWidth > 231:" works, ie. the year is dropped. Setting to 230, the year is back again.

    Not really sure how that bit of code is supposed to work, as both the font size (mine is set to +5) and service width play a part.

  10. #145
    birdman's Avatar
    Title
    Moderator
    Join Date
    Sep 2014
    Location
    Hitchin, UK
    Posts
    7,771
    Thanks
    235
    Thanked 1,656 Times in 1,305 Posts
    Quote Originally Posted by Huevos View Post
    What you are suggesting would only be possible with a fixed width font.
    If there were a way to get the pixel-width that a given piece of text would take up were it displayed then that coudl be used.
    I take it no-one has ever found such a function?
    MiracleBox Prem Twin HD - 2@DVB-T2 + Xtrend et8000 - 5(incl. 2 different USBs)@DVB-T2[terrestrial - UK Freeview HD, Sandy Heath] - LAN/USB-stick/HDD

  11. #146
    Huevos's Avatar
    Title
    Administrator
    Join Date
    Jun 2010
    Location
    38.5N, 0.5W
    Posts
    13,581
    Thanks
    2,004
    Thanked 4,925 Times in 3,259 Posts
    Quote Originally Posted by birdman View Post
    If there were a way to get the pixel-width that a given piece of text would take up were it displayed then that coudl be used.
    I take it no-one has ever found such a function?
    Yes of course you can do it with fixed width font but not true type. e.g.

    True type:
    iiiii
    mmmmm

    Fixed width:
    iiiii
    mmmmm


    And the differing width also depends on the font face, not just that it is true type.
    Help keep OpenViX servers online.Please donate!

  12. #147
    BrokenUnusableAccount
    Quote Originally Posted by Huevos View Post
    Yes of course you can do it with fixed width font but not true type. e.g.

    True type:
    iiiii
    mmmmm

    Fixed width:
    iiiii
    mmmmm


    And the differing width also depends on the font face, not just that it is true type.
    I think birdman wonders if there is a some function you can ask "how wide will this string be in this font", or perhaps, if the renderer is not too advanced and doesn't adjust the widths to suit the neighbouring characters, just "how wide will this character be in this font".

    It seems like something that might exist.
    Last edited by BrokenUnusableAccount; 08-04-21 at 16:17. Reason: typo

  13. The Following User Says Thank You to BrokenUnusableAccount For This Useful Post:

    birdman (08-04-21)

  14. #148
    Huevos's Avatar
    Title
    Administrator
    Join Date
    Jun 2010
    Location
    38.5N, 0.5W
    Posts
    13,581
    Thanks
    2,004
    Thanked 4,925 Times in 3,259 Posts
    Quote Originally Posted by ccs View Post
    Line 927 of Components/EpgListGrid.py looks like this

    Code:
    			fnum = float(timeEpoch)/float(timeSteps)
    			incWidth = int(eventRect.width() / fnum)
    			timeStepsCalc = timeSteps * SECS_IN_MIN
    
    			nowTime = localtime(time())
    			begTime = localtime(timeBase)
    			serviceWidth = serviceRect.width()
    			if nowTime.tm_year == begTime.tm_year and nowTime.tm_yday == begTime.tm_yday:
    				datestr = _("Today")
    			else:
    				if serviceWidth > 179:
    					dateFormat = config.usage.date.daylong.value
    				elif serviceWidth > 129:
    					dateFormat = config.usage.date.dayshort.value
    				elif serviceWidth > 79:
    					dateFormat = config.usage.date.daysmall.value
    				else:
    					dateFormat = "%a"
    				datestr = strftime(dateFormat, begTime)
    I've got Service width in the grid epg set to 225, and the date "Fri 9 Apr 2020" doesn't fit.

    If I mess with EpgListGrid.py and force the date to be "Fri 9 Apr", it fits ok....

    Code:
    			fnum = float(timeEpoch)/float(timeSteps)
    			incWidth = int(eventRect.width() / fnum)
    			timeStepsCalc = timeSteps * SECS_IN_MIN
    
    			nowTime = localtime(time())
    			begTime = localtime(timeBase)
    			serviceWidth = serviceRect.width()
    			if nowTime.tm_year == begTime.tm_year and nowTime.tm_yday == begTime.tm_yday:
    				datestr = _("Today")
    			else:
    				if serviceWidth > 999:
    					dateFormat = config.usage.date.daylong.value
    				elif serviceWidth > 2:
    					dateFormat = config.usage.date.dayshort.value
    				elif serviceWidth > 1:
    					dateFormat = config.usage.date.daysmall.value
    				else:
    					dateFormat = "%a"
    				datestr = strftime(dateFormat, begTime)
    EDIT: If I make the Timeline font size small enough I should be able to see when the date format changes for different service widths.

    Service width of 173 changes the date format (loses the year), Timeline font size -2.
    So as a starting point you need something like this:
    Code:
    			else:
    				if serviceWidth > (self.timelineFontSize + self.epgConfig.timelinefs.value) * 9:
    					dateFormat = config.usage.date.daylong.value
    				elif serviceWidth > (self.timelineFontSize + self.epgConfig.timelinefs.value) * 6.5:
    					dateFormat = config.usage.date.dayshort.value
    				elif serviceWidth > (self.timelineFontSize + self.epgConfig.timelinefs.value) * 4:
    					dateFormat = config.usage.date.daysmall.value
    Help keep OpenViX servers online.Please donate!

  15. The Following User Says Thank You to Huevos For This Useful Post:

    ccs (08-04-21)

  16. #149
    ccs's Avatar
    Title
    ViX Beta Tester
    Join Date
    Sep 2014
    Posts
    5,836
    Thanks
    554
    Thanked 1,276 Times in 1,089 Posts
    .... Thanks, I'll have a go tomorrow.

  17. #150
    Huevos's Avatar
    Title
    Administrator
    Join Date
    Jun 2010
    Location
    38.5N, 0.5W
    Posts
    13,581
    Thanks
    2,004
    Thanked 4,925 Times in 3,259 Posts
    Ok, now I have tried it I need to tweak a bit.

    Code:
    			else:
    				if serviceWidth > (self.timelineFontSize + self.epgConfig.timelinefs.value) * 7.6:
    					dateFormat = config.usage.date.daylong.value
    				elif serviceWidth > (self.timelineFontSize + self.epgConfig.timelinefs.value) * 4.5:
    					dateFormat = config.usage.date.dayshort.value
    				elif serviceWidth > (self.timelineFontSize + self.epgConfig.timelinefs.value) * 2.85:
    					dateFormat = config.usage.date.daysmall.value
    Don't forget some fonts are wider than others, so in skins with narrow fonts such as Magic FHD and iSkin it leaves a bit of extra space, but in all skins it seems to trim the year before it goes out of bounds.
    Help keep OpenViX servers online.Please donate!

Page 10 of 12 FirstFirst ... 89101112 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
This website uses cookies
We use cookies to store session information to facilitate remembering your login information, to allow you to save website preferences, to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners.