fontsize cannot be changed .. why?

Discussion in 'Mac Programming' started by rethish, Jan 18, 2009.

  1. macrumors member

    Oct 16, 2008
    hi all,

    I am totally fedup with managing the text in the textview. I want to set the font size alone .how can i do it ? please help

    If ever i use to set the font ,i use the setfont:(nfont*)fontobj method,here i create a font object,[NSFont fonwithname: size: ]. This works perfectly for setting the font but only partially for setting the size.

    i.e. i can only set fontsize of a particular font.

    actually i need to set the fontsize for the various fonts which is associated with the text.

    [for eg:i needapen.
    here this sentence contains various font styles. If i select all the word and select a particular size then, the complete word's size must change and if i select some part of that sentence and select a particular size that part's size must change..]

    please consider this

    thank you


  2. macrumors newbie

    Jan 7, 2009
    You need to read this guide if you're going to use NSFont and the like.

    Another possible approach is to put everything you want in a WebView and use HTML and CSS to style it. That may ultimately be simpler depending on what you need and what you know, but it comes with a lot of overhead (i.e., learning about how WebView and associated classes work).
  3. thread starter macrumors member

    Oct 16, 2008
    thankyou for considering my post

    Let me try it.


Share This Page