nyctergatis.com

Contact

Projects
Sysquake Remote Live
NME
PDF
Hike
Sudoku
GifBuilder
jpeglib for Palm OS
MySQL Client
Cross-GCC for Mac OS
NMEObjC Usage

NMEObjC - an Objective-C wrapper for NME

Author:
Yves Piguet
See also:
http://www.nyctergatis.com (home of NME project) and http://www.wikicreole.org (Creole site).

Usage

To display text with NME markup in an NSTextView object:

    #import "NMEObjC.h"

    // assume the following variables
    NSTextView *textView;   // NSTextView text is written to
    NSString *nmeInput; // input string with NME markup

    // append nmeInput processed by NME to textView's contents
    NSRange range = NSMakeRange([[output textStorage] length], 0);
    NSData *rtf = [NSData dataWithNMEString:nmeInput fontSize:0 format:'r'];
    [textView replaceCharactersInRange:range withRTF:rtf];
Generated by Doxygen.
Copyright 2007-2013, Yves Piguet.
All rights reserved.