[Bug] Lost spaces in summary (#Plot) after words with length 4 and less (1 Viewer)

ShIvADeSt

Portal Pro
May 30, 2009
71
2
MediaPortal Version: 1.2.0
MediaPortal Skin: DefaultWide
I have in video database in Summary field for example such text "this is mother". But when I start media portal (not configurator) in summary I read that "this ismother" - no space after IS. I check and found that if word' length is less or equal 4 chars space after word is truncated. Fix it please
 

Seidelin

Retired Team Member
  • Premium Supporter
  • August 14, 2006
    1,755
    652
    Kgs. Lyngby
    Home Country
    Denmark Denmark
    Can you maybe provide a screenshot? Logs might be interesting for us as well.
     

    ShIvADeSt

    Portal Pro
    May 30, 2009
    71
    2
    I have Summary with russian letters. With English is all correct (bad example I used), but there screenshots
    attachment.php
    is how it must be
    attachment.php
    is how I see it in MediaPortal

    Please tell which logs are need and how collect it.
     

    Attachments

    • MP.JPG
      MP.JPG
      24.4 KB
    • VideoDB.JPG
      VideoDB.JPG
      15.1 KB

    Deda

    Lead Dev MP1 Videos
  • Premium Supporter
  • March 18, 2009
    2,423
    2,385
    Zagreb
    Home Country
    Croatia Croatia
    Could you zip your videodatabase file (if it's not a problem) and post it here. I'm curious what char code is behind y,k and Ho.
     

    ShIvADeSt

    Portal Pro
    May 30, 2009
    71
    2
    Logs and video database.
    Video file is Пираньи 3D Piranha
    id 1872
     

    Attachments

    • VideoDatabaseV5.zip
      1 MB

    Deda

    Lead Dev MP1 Videos
  • Premium Supporter
  • March 18, 2009
    2,423
    2,385
    Zagreb
    Home Country
    Croatia Croatia
    Ok thx for files, I will check it out (no problem about chars, I can read Cyrillic letters and understand a little Russian :) )
     

    Deda

    Lead Dev MP1 Videos
  • Premium Supporter
  • March 18, 2009
    2,423
    2,385
    Zagreb
    Home Country
    Croatia Croatia
    Can you tell what scrapper you use, there is a problem in characters because they are not properly decoded in script. Spaces in you your examples are not real spaces so you have chars which are not allowed in HTML into character-entity equivalents so they must be decoded first to reverse the encoding.
     

    ShIvADeSt

    Portal Pro
    May 30, 2009
    71
    2
    Its a kinopoisk scrapper, written specially for russian site - kinopoisk.ru - full film base with russian description and etc. But it's very strange, coz I use this grabber at least 1 year and MP 1.1.0 show summary without losing spaces.
    I open hml code of page and saw it (  after problem words)
    у озера Виктория готовятся к пра Но ночное землетрясени
    I think that early MP just show this non-space symbol but now it stripped from text
     

    Deda

    Lead Dev MP1 Videos
  • Premium Supporter
  • March 18, 2009
    2,423
    2,385
    Zagreb
    Home Country
    Croatia Croatia
    There was a changes in font engine within MP so maybe that introduced your problem, in plain NET forms, as you can see, they are shown as spaces and also while debugging text is OK in variables, but when those chars ends within texture engine result is connected words.

    We can do 3 things:

    1. Add HttpUtility.HtmlDecode(string) in script (MP code will stay untouched, but you will have to refresh your movies with new script)
    2. I can add HttpUtility.HtmlDecode in skin properties (not a problem but we will need to wait next release)
    3. Change font texture engine (which I doubt it will be done)

    Finally, I saw you movie collection and it's very well populated, if you're satisfied with script result I can add it to a standard scripts for MP so script can be fetched/refreshed as other MP script via configuration.


    I would like comments from the Team about those 3 options above and what to do.
     

    ShIvADeSt

    Portal Pro
    May 30, 2009
    71
    2
    We can do 3 things:

    1. Add HttpUtility.HtmlDecode(string) in script (MP code will stay untouched, but you will have to refresh your movies with new script)
    2. I can add HttpUtility.HtmlDecode in skin properties (not a problem but we will need to wait next release)
    3. Change font texture engine (which I doubt it will be done)
    In scrapper script I found this
    result = HttpUtility.HtmlDecode(result);
    and nothing happend, all   still as symbol 0xA0. So I add this line in scrapper
    result = Regex.Replace(result, @"\xA0", " ");
    and now all scrapped correct. All I need is update summary for all files. Its simple SQL call.
    :D for advice about wrong symbol code and HtmlDecode - it's give me a sign how to improve.
     

    Users who are viewing this thread

    Top Bottom