Hello there,

I have an NSText object inside a box in a panel which I create like this:

    fontdisp = [[NSText alloc] initWithFrame:[[box contentView] frame]];
    [fontdisp setString:_(@"The quick brown fox jumps over the lazy
dog.")];
    [fontdisp setAlignment:NSCenterTextAlignment];
    [fontdisp setFont:[NSFont userFontOfSize:24]];
    [fontdisp setRichText:YES];
    [fontdisp setUsesFontPanel:YES];
    [fontdisp setDelegate:self];
    [box setContentView:fontdisp];

I cannot get it to change fonts via the set button on the font panel even
though the code is the same as in Ink.app.

I obtained the font menu like this:

[[NSFontManager sharedFontManager] fontMenu: YES].

Oddly enough the menu entries "Bold", "Italic", "Larger" etc. do work and
change the current selection. I just cannot set the font with the set
button. Also, I would like the user only to be able to change the font of
the entire contents of the text object, but when I turn rich text off, the
object stops accepting changes alltogether, or rather, it does not display
them properly. The text is not bold but the menu item reads "unbold."

Best regards,

Marko




+-------------------------------------------------------------+
| Marko Riedel, EDV Neue Arbeit gGmbH, [EMAIL PROTECTED] |
| http://www.geocities.com/markoriedelde/index.html           |
+-------------------------------------------------------------+


        

        
                
___________________________________________________________ 
Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de


_______________________________________________
Discuss-gnustep mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/discuss-gnustep

Reply via email to