# Source for file objc.php

Documentation is available at objc.php

    1     <?php
    2     /***********************************************************************************
    3      * objc.php
    4      * --------
    5      * Author: M. Uli Kusterer (witness.of.teachtext@gmx.net)
    6      * Copyright: (c) 2004 M. Uli Kusterer, Nigel McNie (http://qbnz.com/highlighter/)
    7      * Release Version: 1.0.7.3
    8      * CVS Revision Version: $Revision: 1.1 $
    9      * Date Started: 2004/06/04
    10     * Last Modified: $Date: 2006/01/23 09:27:29 $
    11     *
    12     * Objective C language file for GeSHi.
    13     *
    14     * CHANGES
    15     * -------
    16     * 2004/11/27 (1.0.0)
    17     *   -  First Release
    18     *
    19     * TODO (updated 2004/11/27)
    20     * -------------------------
    21     *
    22     ************************************************************************************
    23     *
    24     *     This file is part of GeSHi.
    25     *
    26     *   GeSHi is free software; you can redistribute it and/or modify
    27     *   it under the terms of the GNU General Public License as published by
    28     *   the Free Software Foundation; either version 2 of the License, or
    29     *   (at your option) any later version.
    30     *
    31     *   GeSHi is distributed in the hope that it will be useful,
    32     *   but WITHOUT ANY WARRANTY; without even the implied warranty of
    33     *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    34     *   GNU General Public License for more details.
    35     *
    36     *   You should have received a copy of the GNU General Public License
    37     *   along with GeSHi; if not, write to the Free Software
    38     *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
    39     *
    40     ************************************************************************************/
    40
    41
    42    $language_data = array (
    43        'LANG_NAME' => 'Objective C',
    44        'COMMENT_SINGLE' => array(1 => '//', 2 => '#'),
    45        'COMMENT_MULTI' => array('/*' => '*/'),
    46        'CASE_KEYWORDS' => GESHI_CAPS_NO_CHANGE,
    47        'QUOTEMARKS' => array("'", '"'),
    48        'ESCAPE_CHAR' => '\\',
    49        'KEYWORDS' => array(
    50            1 => array(
    51                'if', 'return', 'while', 'case', 'continue', 'default',
    52                'do', 'else', 'for', 'switch', 'goto'
    53                ),
    54            2 => array(
    55                'NULL', 'false', 'break', 'true', 'enum', 'nil', 'Nil', 'errno', 'EDOM',
    56                'ERANGE', 'FLT_RADIX', 'FLT_ROUNDS', 'FLT_DIG', 'DBL_DIG', 'LDBL_DIG',
    57                'FLT_EPSILON', 'DBL_EPSILON', 'LDBL_EPSILON', 'FLT_MANT_DIG', 'DBL_MANT_DIG',
    58                'LDBL_MANT_DIG', 'FLT_MAX', 'DBL_MAX', 'LDBL_MAX', 'FLT_MAX_EXP', 'DBL_MAX_EXP',
    59                'LDBL_MAX_EXP', 'FLT_MIN', 'DBL_MIN', 'LDBL_MIN', 'FLT_MIN_EXP', 'DBL_MIN_EXP',
    60                'LDBL_MIN_EXP', 'CHAR_BIT', 'CHAR_MAX', 'CHAR_MIN', 'SCHAR_MAX', 'SCHAR_MIN',
    61                'UCHAR_MAX', 'SHRT_MAX', 'SHRT_MIN', 'USHRT_MAX', 'INT_MAX', 'INT_MIN',
    62                'UINT_MAX', 'LONG_MAX', 'LONG_MIN', 'ULONG_MAX', 'HUGE_VAL', 'SIGABRT',
    63                'SIGFPE', 'SIGILL', 'SIGINT', 'SIGSEGV', 'SIGTERM', 'SIG_DFL', 'SIG_ERR',
    64                'SIG_IGN', 'BUFSIZ', 'EOF', 'FILENAME_MAX', 'FOPEN_MAX', 'L_tmpnam', 'NULL',
    65                'SEEK_CUR', 'SEEK_END', 'SEEK_SET', 'TMP_MAX', 'stdin', 'stdout', 'stderr',
    66                'EXIT_FAILURE', 'EXIT_SUCCESS', 'RAND_MAX', 'CLOCKS_PER_SEC'
    67                ),
    68            3 => array(
    69                'printf', 'fprintf', 'snprintf', 'sprintf', 'assert',
    70                'isalnum', 'isalpha', 'isdigit', 'iscntrl', 'isgraph', 'islower', 'isprint',
    71                'ispunct', 'isspace', 'ispunct', 'isupper', 'isxdigit', 'tolower', 'toupper',
    72                'exp', 'log', 'log10', 'pow', 'sqrt', 'ceil', 'floor', 'fabs', 'ldexp',
    73                'frexp', 'modf', 'fmod', 'sin', 'cos', 'tan', 'asin', 'acos', 'atan', 'atan2',
    74                'sinh', 'cosh', 'tanh', 'setjmp', 'longjmp', 'asin', 'acos', 'atan', 'atan2',
    75                'va_start', 'va_arg', 'va_end', 'offsetof', 'sizeof', 'fopen', 'freopen',
    76                'fflush', 'fclose', 'remove', 'rename', 'tmpfile', 'tmpname', 'setvbuf',
    77                'setbuf', 'vfprintf', 'vprintf', 'vsprintf', 'fscanf', 'scanf', 'sscanf',
    78                'fgetc', 'fgets', 'fputc', 'fputs', 'getc', 'getchar', 'gets', 'putc',
    79                'putchar', 'puts', 'ungetc', 'fread', 'fwrite', 'fseek', 'ftell', 'rewind',
    80                'fgetpos', 'fsetpos', 'clearerr', 'feof', 'ferror', 'perror', 'abs', 'labs',
    81                'div', 'ldiv', 'atof', 'atoi', 'atol', 'strtod', 'strtol', 'strtoul', 'calloc',
    82                'malloc', 'realloc', 'free', 'abort', 'exit', 'atexit', 'system', 'getenv',
    83                'bsearch', 'qsort', 'rand', 'srand', 'strcpy', 'strncpy', 'strcat', 'strncat',
    84                'strcmp', 'strncmp', 'strcoll', 'strchr', 'strrchr', 'strspn', 'strcspn',
    85                'strpbrk', 'strstr', 'strlen', 'strerror', 'strtok', 'strxfrm', 'memcpy',
    86                'memmove', 'memcmp', 'memchr', 'memset', 'clock', 'time', 'difftime', 'mktime',
    87                'asctime', 'ctime', 'gmtime', 'localtime', 'strftime'
    88                ),
    89            4 => array(   // Data types:
    90                'auto', 'char', 'const', 'double',  'float', 'int', 'long',
    91                'register', 'short', 'signed', 'sizeof', 'static', 'string', 'struct',
    92                'typedef', 'union', 'unsigned', 'void', 'volatile', 'extern', 'jmp_buf',
    93                'signal', 'raise', 'va_list', 'ptrdiff_t', 'size_t', 'FILE', 'fpos_t',
    94                'div_t', 'ldiv_t', 'clock_t', 'time_t', 'tm',
    95                // OpenStep/GNUstep/Cocoa:
    96                'SEL', 'id', 'NSRect', 'NSRange', 'NSPoint', 'NSZone', 'Class', 'IMP', 'BOOL',
    97                // OpenStep/GNUstep/Cocoa @identifiers
    98                '@selector', '@class', '@protocol', '@interface', '@implementation', '@end',
    99                '@private', '@protected', '@public', '@try', '@throw', '@catch', '@finally',
    100               '@encode', '@defs', '@synchronized'
    101               ),
    102           5 => array( // OpenStep/GNUstep/Cocoa Foundation
    103               'NSAppleEventDescriptor', 'NSNetService', 'NSAppleEventManager',
    104               'NSNetServiceBrowser', 'NSAppleScript', 'NSNotification', 'NSArchiver',
    105               'NSNotificationCenter', 'NSArray', 'NSNotificationQueue', 'NSAssertionHandler',
    106               'NSNull', 'NSAttributedString', 'NSNumber', 'NSAutoreleasePool',
    107               'NSNumberFormatter', 'NSBundle', 'NSObject', 'NSCachedURLResponse',
    108               'NSOutputStream', 'NSCalendarDate', 'NSPipe', 'NSCharacterSet', 'NSPort',
    109               'NSClassDescription', 'NSPortCoder', 'NSCloneCommand', 'NSPortMessage',
    110               'NSCloseCommand', 'NSPortNameServer', 'NSCoder', 'NSPositionalSpecifier',
    111               'NSConditionLock', 'NSProcessInfo', 'NSConnection', 'NSPropertyListSerialization',
    112               'NSCountCommand', 'NSPropertySpecifier', 'NSCountedSet', 'NSProtocolChecker',
    113               'NSCreateCommand', 'NSProxy', 'NSData', 'NSQuitCommand', 'NSDate',
    114               'NSRandomSpecifier', 'NSDateFormatter', 'NSRangeSpecifier', 'NSDecimalNumber',
    115               'NSRecursiveLock', 'NSDecimalNumberHandler', 'NSRelativeSpecifier',
    116               'NSDeleteCommand', 'NSRunLoop', 'NSDeserializer', 'NSScanner', 'NSDictionary',
    117               'NSScriptClassDescription', 'NSDirectoryEnumerator', 'NSScriptCoercionHandler',
    118               'NSDistantObject', 'NSScriptCommand', 'NSDistantObjectRequest',
    119               'NSScriptCommandDescription', 'NSDistributedLock', 'NSScriptExecutionContext',
    120               'NSDistributedNotificationCenter', 'NSScriptObjectSpecifier', 'NSEnumerator',
    121               'NSScriptSuiteRegistry', 'NSError', 'NSScriptWhoseTest', 'NSException',
    122               'NSSerializer', 'NSExistsCommand', 'NSSet', 'NSFileHandle', 'NSSetCommand',
    123               'NSFileManager', 'NSSocketPort', 'NSFormatter', 'NSSocketPortNameServer',
    124               'NSGetCommand', 'NSSortDescriptor', 'NSHost', 'NSSpecifierTest', 'NSHTTPCookie',
    125               'NSSpellServer', 'NSHTTPCookieStorage', 'NSStream', 'NSHTTPURLResponse',
    126               'NSString', 'NSIndexSet', 'NSTask', 'NSIndexSpecifier', 'NSThread',
    127               'NSInputStream', 'NSTimer', 'NSInvocation', 'NSTimeZone', 'NSKeyedArchiver',
    128               'NSUnarchiver', 'NSKeyedUnarchiver', 'NSUndoManager', 'NSLock',
    129               'NSUniqueIDSpecifier', 'NSLogicalTest', 'NSURL', 'NSMachBootstrapServer',
    130               'NSURLAuthenticationChallenge', 'NSMachPort', 'NSURLCache', 'NSMessagePort',
    131               'NSURLConnection', 'NSMessagePortNameServer', 'NSURLCredential',
    132               'NSMethodSignature', 'NSURLCredentialStorage', 'NSMiddleSpecifier',
    133               'NSURLDownload', 'NSMoveCommand', 'NSURLHandle', 'NSMutableArray',
    134               'NSURLProtectionSpace', 'NSMutableAttributedString', 'NSURLProtocol',
    135               'NSMutableCharacterSet', 'NSURLRequest', 'NSMutableData', 'NSURLResponse',
    136               'NSMutableDictionary', 'NSUserDefaults', 'NSMutableIndexSet', 'NSValue',
    137               'NSMutableSet', 'NSValueTransformer', 'NSMutableString', 'NSWhoseSpecifier',
    138               'NSMutableURLRequest', 'NSXMLParser', 'NSNameSpecifier'
    139           ),
    140           6 => array( // OpenStep/GNUstep/Cocoa AppKit
    141               'NSActionCell', 'NSOpenGLPixelFormat', 'NSAffineTransform', 'NSOpenGLView',
    142               'NSAlert', 'NSOpenPanel', 'NSAppleScript Additions', 'NSOutlineView',
    143               'NSApplication', 'NSPageLayout', 'NSArrayController', 'NSPanel',
    144               'NSATSTypesetter', 'NSParagraphStyle', 'NSPasteboard', 'NSBezierPath',
    145               'NSPDFImageRep', 'NSBitmapImageRep', 'NSPICTImageRep', 'NSBox', 'NSPopUpButton',
    146               'NSBrowser', 'NSPopUpButtonCell', 'NSBrowserCell', 'NSPrinter', 'NSPrintInfo',
    147               'NSButton', 'NSPrintOperation', 'NSButtonCell', 'NSPrintPanel', 'NSCachedImageRep',
    148               'NSProgressIndicator', 'NSCell', 'NSQuickDrawView', 'NSClipView', 'NSResponder',
    149               'NSRulerMarker', 'NSColor', 'NSRulerView', 'NSColorList', 'NSSavePanel',
    150               'NSColorPanel', 'NSScreen', 'NSColorPicker', 'NSScroller', 'NSColorWell',
    151               'NSScrollView', 'NSComboBox', 'NSSearchField', 'NSComboBoxCell',
    152               'NSSearchFieldCell', 'NSControl', 'NSSecureTextField', 'NSController',
    153               'NSSecureTextFieldCell', 'NSCursor', 'NSSegmentedCell', 'NSCustomImageRep',
    154               'NSSegmentedControl', 'NSDocument', 'NSShadow', 'NSDocumentController',
    155               'NSSimpleHorizontalTypesetter', 'NSDrawer', 'NSSlider', 'NSEPSImageRep',
    156               'NSSliderCell', 'NSEvent', 'NSSound', 'NSFileWrapper', 'NSSpeechRecognizer',
    157               'NSFont', 'NSSpeechSynthesizer', 'NSFontDescriptor', 'NSSpellChecker',
    158               'NSFontManager', 'NSSplitView', 'NSFontPanel', 'NSStatusBar', 'NSForm',
    159               'NSStatusItem', 'NSFormCell', 'NSStepper', 'NSGlyphGenerator', 'NSStepperCell',
    160               'NSGlyphInfo', 'NSGraphicsContext', 'NSTableColumn', 'NSHelpManager',
    161               'NSTableHeaderCell', 'NSImage', 'NSTableHeaderView', 'NSImageCell', 'NSTableView',
    162               'NSImageRep', 'NSTabView', 'NSImageView', 'NSTabViewItem', 'NSInputManager',
    163               'NSText', 'NSInputServer', 'NSTextAttachment', 'NSLayoutManager',
    164               'NSTextAttachmentCell', 'NSMatrix', 'NSTextContainer', 'NSMenu', 'NSTextField',
    165               'NSMenuItem', 'NSTextFieldCell', 'NSMenuItemCell', 'NSTextStorage', 'NSMenuView',
    166               'NSTextTab', 'NSMovie', 'NSTextView', 'NSMovieView', 'NSToolbar', 'NSToolbarItem',
    167               'NSMutableParagraphStyle', 'NSTypesetter', 'NSNib', 'NSNibConnector',
    168               'NSUserDefaultsController', 'NSNibControlConnector', 'NSView',
    169               'NSNibOutletConnector', 'NSWindow', 'NSObjectController', 'NSWindowController',
    170               'NSOpenGLContext', 'NSWorkspace', 'NSOpenGLPixelBuffer'
    171           )
    172       ),
    173       'SYMBOLS' => array(
    174           '(', ')', '{', '}', '[', ']', '=', '+', '-', '*', '/', '!', '%', '^', '&', ':'
    175           ),
    176       'CASE_SENSITIVE' => array(
    177           GESHI_COMMENTS => true,
    178           1 => false,
    179           2 => false,
    180           3 => false,
    181           4 => false,
    182           5 => false,
    183           6 => false,
    184           ),
    185       'STYLES' => array(
    186           'KEYWORDS' => array(
    187               1 => 'color: #0000ff;',
    188               2 => 'color: #0000ff;',
    189               3 => 'color: #0000dd;',
    190               4 => 'color: #0000ff;',
    191               5 => 'color: #0000ff;',
    192               6 => 'color: #0000ff;'
    193               ),
    194           'COMMENTS' => array(
    195               1 => 'color: #ff0000;',
    196               2 => 'color: #339900;',
    197               'MULTI' => 'color: #ff0000; font-style: italic;'
    198               ),
    199           'ESCAPE_CHAR' => array(
    200               0 => 'color: #666666; font-weight: bold;'
    201               ),
    202           'BRACKETS' => array(
    203               0 => 'color: #002200;'
    204               ),
    205           'STRINGS' => array(
    206               0 => 'color: #666666;'
    207               ),
    208           'NUMBERS' => array(
    209               0 => 'color: #0000dd;'
    210               ),
    211           'METHODS' => array(
    212               ),
    213           'SYMBOLS' => array(
    214               0 => 'color: #002200;'
    215               ),
    216           'REGEXPS' => array(
    217               ),
    218           'SCRIPT' => array(
    219               )
    220           ),
    221       'URLS' => array(
    222           1 => '',
    223           2 => '',
    224           3 => 'http://www.opengroup.org/onlinepubs/009695399/functions/{FNAME}.html',
    225           4 => '',
    226           5 => 'http://developer.apple.com/documentation/Cocoa/Reference/Foundation/ObjC_classic/Classes/{FNAME}.html',
    227           6 => 'http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/ObjC_classic/Classes/{FNAME}.html'
    228           ),
    229       'OOLANG' => false,
    230       'OBJECT_SPLITTERS' => array(
    231           ),
    232       'REGEXPS' => array(
    233           ),
    234       'STRICT_MODE_APPLIES' => GESHI_NEVER,
    235       'SCRIPT_DELIMITERS' => array(
    236           ),
    237       'HIGHLIGHT_STRICT_BLOCK' => array(
    238           )
    239   );
    240
    241   ?>

Documentation generated on Thu, 22 Sep 2005 13:48:03 +1200 by phpDocumentor 1.2.3