0

Chinese characters and others

Hi all. I am new to this and I am doing on a widget which shows tweets of a particular twitter which has a mixture of english and chinese tweets. I have used the RSS Feed Example in Widget Realm and encountered several problems. Is there a way to show chinese characters? May I know why the tweets shown in my widget are shown in a straight line instead of a paragraph when it is too long, which means when the tweet is very long, I only can see a part of it.

by
9 Replies
  • No sure on the Chinese Characters.

    For the multiple line text, set the "wrap" style property.

    CODE
    new KONtx.element.Text({label:"Single Line",styles:{/*Styles Values*/}});

    new KONtx.element.Text({label:"Mutiple Line",styles:{width: 294, wrap:true, /*Styles Values*/}});
    0
  • QUOTE (siaokina @ Mar 10 2011, 12:28 AM) <{POST_SNAPBACK}>
    Hi all. I am new to this and I am doing on a widget which shows tweets of a particular twitter which has a mixture of english and chinese tweets. I have used the RSS Feed Example in Widget Realm and encountered several problems. Is there a way to show chinese characters?

    It's a font issue. The wdk and the tvs don't have the necessary fonts to display non-latin characters, unfortunately.

    QUOTE (siaokina @ Mar 10 2011, 12:28 AM) <{POST_SNAPBACK}>
    May I know why the tweets shown in my widget are shown in a straight line instead of a paragraph when it is too long, which means when the tweet is very long, I only can see a part of it.

    As was said, use the wrap property. Though it will be honored outside of the styles object, I put it inside with my other css styles.
    0
  • Thanks for the replies and help.

    Another question:

    Can Yahoo! TV widget have a share in Facebook function?
    0
  • QUOTE (siaokina @ Mar 10 2011, 09:57 PM) <{POST_SNAPBACK}>
    Can Yahoo! TV widget have a share in Facebook function?

    I'm afraid I don't understand your question.
    0
  • QUOTE (Benjamin Toll @ Mar 10 2011, 11:51 PM) <{POST_SNAPBACK}>
    I'm afraid I don't understand your question.


    Sorry, I meant can I have a "Facebook Share function" on information feeds in widgets?
    0
  • QUOTE (siaokina @ Mar 11 2011, 12:47 AM) <{POST_SNAPBACK}>
    Sorry, I meant can I have a "Facebook Share function" on information feeds in widgets?

    Yes. You'll have to get a developer key from them and start digging into their APIs. I've never done it myself.
    0
  • QUOTE (Benjamin Toll @ Mar 11 2011, 11:59 AM) <{POST_SNAPBACK}>
    Yes. You'll have to get a developer key from them and start digging into their APIs. I've never done it myself.


    Thank you! You have been a great help to me!
    0
  • window.open("http://www.facebook.com/share.php?u=http://www.yahoo.com");

    I have this code with me that works in javascript in HTML but does not work in the javascript code for my button.

    this.controls['button'] = new KONtx.control.TextButton({
    label: 'Share to Facebook',
    styles: $content.styles.main.button, //Style information for the Button stored in our 960x540.js file
    events:{
    //Setup a onSelect Event to handle the button action
    onSelect:function(event){
    window.open("http://www.facebook.com/share.php?u=http://www.yahoo.com");
    }
    }
    }).appendTo(this);

    Is there any problem with my code?
    0
  • there is no window.open() command in the SDK. AND not HTML browser support... :b
    0

Recent Posts

in Getting Started / Beginners - Yahoo! TV Widgets