MyWebUniversity.com Home Page
 



Darwin Mac OS X man pages main menu
NIBTOL(1)                         Computer,                        NIBTOL(1)



NAME
       nibtool - prints, verifies, and updates nib files.


SYNOPSIS
       nibtool -[acFhjrsvdpwWxBILOPCV8Rlf?]  nibfile

DESCRIPTION
       nibtool  lets  you print, update, and verify the contents of a nib file
       from the command line.

       You can use nibtool to produce text descriptions for two different ver-
       sions of the same nib file and then compare them with diff.

       The output of nibtool is produced in standard plist format.

       The  default  output  encoding  of nibtool is UTF-16.  The output/input
       format is controlled with the --utf8 or --macosroman flags.


OPTIONS
       -F,, --format TYPE
              Saves the nib file in one of 5 formats: 1 Pre-10.2 format (type-
              dstreams;  can  be used on all versions; can't take advantage of
              new features).  2 10.2 and later format (keyed archiving; can be
              used  on  new  versions).   3  Both  formats  (incorporates both
              files).  (Does not apply to Carbon Nib files).  4 10.2 and later
              format  (keyed archiving in text format; can be used on new ver-
              sions).  5 Both formats (incorporates both files,  archives  the
              10.2  and  later  file as text and archives the pre 10.2 file as
              binary).  (Does not apply to Carbon Nib files).  If  -F  if  not
              specified the format of the nib file is not changed.

       -c,, --classes
              Prints  the  local classes created in nibfile and a list of out-
              lets and actions of the classes.  (Does not apply to Carbon  Nib
              files)

       -h,, --hierarchy
              Prints the object hierarchy in nibfile This is equivalent to the
              outline view in Interface Builder.

       -j,, --objects
              Prints the settings of all of the objects in nibfile.

       -x,, --connections
              Prints the connections in nibfile.  List of outlets and  actions
              for all of the objects in the nib file.  (Does not apply to Car-
              bon Nib files)

       -a,, --all
              Prints the classes, object hierarchy, object values, and connec-
              tions in the nibfile.  It's equivalent to -chjx.

       -L,, --localizable-strings
              Prints the localizable strings in nibfile in plist format.

       -B,, --bundle bundle
              Loads  bundle before loading nibfile.  This is useful if nibfile
              requires a class in bundle.  to load.

       -O,, --use-oids
              Use unique object identifiers instead of the  object  titles  in
              the  localization  dictionary.  If  the object has more than one
              localization string possible, then the key will look like  oid.#
              where  # is an integer. If the input dictionary was created with
              this option, then the input dictionary will only work if  it  is
              read in with this option.

       -e,, --export PLISTFILE
              For  each  object in the nib, export the properties specified in
              PLISTFILE to a property list. PLISTFILE is  a  path  to  an  XML
              plist.   The  plist  should  contain  a dictionary of class name
              arrays containing strings of key paths for properties. The  out-
              put  is  a  dictionary  in XML plist format where each key is an
              object ID, and each value is a dictionary of key paths and their
              associated value. If a key in the second level dictionary begins
              with a '.', it isn't a key path.  Currently,  the  only  special
              key is ".nilKeypaths". It identifies an array of key paths whose
              value was nil.

       -i,, --import PLISTFILE
              For each object in the nib identified by the contents of  PLIST-
              FILE,  take the properties specified in PLISTFILE and apply them
              to the object.  PLISTFILE is in the format of the output of  the
              --export  command. Be aware that setting a property may have the
              side effect of not actually changing the  property  or  possibly
              altering  additional  properties.  Typically this option is com-
              bined with -w, -W, or -r.

       -P,, --palette palette
              Loads palette before loading nibfile.  This is useful if nibfile
              contains a class defined in palette nibtool will by default load
              in all palettes that the user has selected to load  into  Inter-
              face Builder.

       -C,, --convert old new
              Convert  all custom classes in nibfile that have prefix old into
              new. Can be used to convert all classes whose name  begins  with
              com.apple.yellow  to  now  be prefixed by com.apple.cocoa or all
              classes that have the prefix XY to now have the prefix XZ.

       -w,, --write new-nibfile
              Updates nibfile to the latest nib version and writes it  out  to
              new-nibfile.

       -W,, --Write new-nibfile
              Updates  nibfile  to the latest nib version and writes it out to
              new-nibfile (Overwrite new-nibfile.  even if it already exits)

       -r,, --resave
              Perform all the operations specified on the command line on nib-
              file  and  save  it  back  over  writing the original file. This
              option can be used to "update" the objects to the newest version
              in the AppKit.

       -s,, --silent
              Silent mode. Only verifies the nibfile and prints only errors.

       -v,, --verbose
              Verbose mode, a full report is printed.

       -d,, --dictionary strings
              Upon loading, translate strings using the stringsfile strings as
              dictionary.

       -p,, --previous nibfile
              When performing incremental localization, make use  of  informa-
              tion from the previous non-localized nibfile.

       -I,, --incremental nibfile
              Make  use  of  layout information from a previous localized nib-
              file.  If the previous non-localized nibfile, oSource.nib  ,  is
              also  provided  using  the -p option, localized attributes for a
              given element in nibfile are  only  applied  if  that  element's
              attribute was not changed between oSource.nib and the new source
              nib file. If no previous nibfile is specified, all  localization
              changes in nibfile are applied to the new nibfile.

       -l,, --localizable-attributes argument
              Specify  which attributes should be copied to the nib file argu-
              ment is specified in plist format "(value1,value2,value3)".  The
              default value is "(dateFormat, stringFrame, cellSizeString, con-
              tentRectString, titleWidth, minSizeString, maxSizeString, width,
              maxWidth,  minWidth,  title,  stringValue,  alternateTitle, con-
              trolTitle, radioTitles, label, helpTagText)"

       -8,, --utf8
              Set the encoding of the output/input to UTF-8 default is Unicode
              (UTF-16). The default encoding expected for the input is UTF-16.

       -R,, --macosroman
              Set the encoding of the  output/input  to  MacOSRoman.  (twobyte
              characters are escaped.)

       -f,, --fontcheck nibfile
              Set  the font of the objects in the current nib file to the same
              fonts as used in nibfile

       -V,, --version
              Print out the Build Version of the program.

       -n,, --nib-version
              Print the version of IB/System Version used  to  when  this  nib
              file  was  last saved. The first number is the version of Inter-
              face Builder that was used and the second number is the  version
              of  the operating system that was used when this file was saved.

       -??,, --help
              Print out the usage message.

EXAMPLES
       nibtool -a file.nib
              Dump ascii representation of file.nib.

       nibtool -L file.nib >> file.strings
              Generates translation dictionary file.strings for file.nib.

       nibtool -w nFile.nib -d file.strings file.nib
              Reloads in the translation dictionary  file.strings  and  writes
              out a new file nFile.nib with translated strings.

       nibtool -I oFile.nib -w nFile.nib -d file.strings file.nib
              Uses  the  layout  information  in  oFile.nib and the translated
              strings file file.strings to generate nFile.nib.  This  is  used
              when  the  developer has added a new control to file.nib but all
              of the nib files have already been localized (i.e. the  size  of
              the  controls has already been adjusted). This command will make
              the size of the objects in nFile.nib match the sizes of the same
              objects  in oFile.nib.  This is an aggressive use of the -incre-
              mental localization option, and requires reviewing the new  nib-
              file to ensure developer's changes were not written over.

       nibtool   -I   oLocalized.nib   -p  oSource.nib  -w  nLocalized.nib  -d
       file.strings file.nib
              Copy localized attributes from oLocalized.nib into nLocaized.nib
              if that attribute is the same in oSource.nib and file.nib.   Any
              strings  will  be  translated  using  the translation dictionary
              file.strings.  This is a conservative  incremental  localization
              approach,  and  requires  review  of  the nLocalized.nib file to
              localize any new elements. You use  this  when  the  translation
              group  translated  sSource.nib  to created -> oLocalized.nib the
              developer latter edited oSource.nib and created -> file.nib  (or
              the new version of the non localized resource).


SEE ALSO
       diff(1)


BUGS
       You cannot regenerate a nib file using the output of nibtool.



Apple                            Jul 10 2003                        NIBTOL(1)
Darwin Mac OS X man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™