# HG changeset patch
# User Pantxo Diribarne <pantxo.diribarne@gmail.com>
# Date 1572367262 -3600
#      Tue Oct 29 17:41:02 2019 +0100
# Node ID 8978481886f1aca1cc6b611ffefe5e3d452c8608
# Parent  08394c4cf18034d79d65ebde6bd002fa4c10e598
genpropdoc.m: Add categories for better readability

* genpropdoc.m (getdoc): Add new field "category" which defaults to
  "miscellaneous". Give most documented properties a category.
  (printdoc): use @chapheading to display categories.

diff -r 08394c4cf180 -r 8978481886f1 doc/interpreter/genpropdoc.m
--- a/doc/interpreter/genpropdoc.m	Mon Oct 28 17:14:51 2019 -0700
+++ b/doc/interpreter/genpropdoc.m	Tue Oct 29 17:41:02 2019 +0100
@@ -91,6 +91,8 @@
   ## -"printdefault": a boolean (def. true) that specifies whether the
   ##   default value should be printed.  It is useful for properties
   ##   like root "screendepth" that default to screen dependent values.
+  ##
+  ## -"category": a string that is used to order properties.
 
   packopt = @(c) strjoin (c, " | ");
   markdef = @(s) ["@{" s "@}"];
@@ -126,7 +128,8 @@
   if (isfield (base, field))
     s = base.(field);
   else
-    s = struct ("valid", "", "default", "", "doc", "", "printdefault", true);
+    s = struct ("valid", "", "default", "", "doc", "", ...
+                "printdefault", true, "category", "Miscellaneous");
   endif
 
   ## Base properties: Write generic documentation because it will be included
@@ -136,6 +139,8 @@
   if (strcmp (objname, "base"))
     switch (field)
       case "beingdeleted"
+        s.category = "Creation/Deletion";
+        
       case "busyaction"
         s.doc = "Define how Octave handles the execution of this object's \
 callback properties when it is unable to interrupt another object's \
@@ -145,18 +150,22 @@
 indicates whether the interrupting callback is queued (@qcode{\"queue\"} \
 (default)) or discarded (@qcode{\"cancel\"}).\n\
 @xref{Callbacks, , @w{Callbacks section}}.";
+        s.category = "Callback Execution";
 
       case "buttondownfcn"
         s.doc = "__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Mouse Interaction";
 
       case "children"
         s.doc = "Graphics handles of the __objname__'s children.";
         s.valid = "vector of graphics handles";
+        s.category = "Parent / Children";
 
       case "clipping"
         s.doc = "If __prop__ is @qcode{\"on\"}, the __objname__ is \
 clipped in its parent axes limits.";
+        s.category = "Display";
 
       case "createfcn"
         s.doc = "Callback function executed immediately after __objname__ \
@@ -164,11 +173,13 @@
 e.g., @code{set (groot, \"default__objname__createfcn\", \
 'disp (\"__objname__ created!\")')}.\n\n__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Creation/Deletion";
 
       case "deletefcn"
         s.doc = "Callback function executed immediately before __objname__ \
 is deleted.\n\n__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Creation/Deletion";
 
       case "handlevisibility"
         s.doc = "If __prop__ is @qcode{\"off\"}, the __objname__'s \
@@ -182,6 +193,7 @@
 @qcode{\"currentobject\"}.  This property is only relevant when the object \
 can accept mouse clicks which is determined by the @qcode{\"pickableparts\"} \
 property.  @xref{XREF__objname__pickableparts, , @w{pickableparts property}}.";
+        s.category = "Mouse Interaction";
 
       case "interruptible"
         s.doc = "Specify whether this object's callback functions may be \
@@ -189,10 +201,12 @@
 and callbacks that make use of @code{drawnow}, @code{figure}, @code{waitfor}, \
 @code{getframe} or @code{pause} functions are eventually interrupted.\n\
 @xref{Callbacks, , @w{Callbacks section}}.";
+        s.category = "Callback Execution";
 
       case "parent"
         s.doc = "Handle of the parent graphics object.";
         s.valid = valid_handle;
+        s.category = "Parent / Children";
 
       case "pickableparts"
         s.doc = "Specify whether __objname__ will accept mouse clicks.  \
@@ -204,9 +218,12 @@
 object is configured to accept mouse clicks the @qcode{\"hittest\"} property \
 will determine how they are processed.  \
 @xref{XREF__objname__hittest, , @w{hittest property}}.";
+        s.category = "Mouse Interaction";
 
       case "selected"
+        s.category = "Mouse Interaction";
       case "selectionhighlight"
+        s.category = "Mouse Interaction";
       case "tag"
         s.doc = "A user-defined string to label the graphics object.";
         s.valid = valid_string;
@@ -221,6 +238,7 @@
         s.doc = "Graphics handle of the uicontextmenu object that is \
 currently associated to this __objname__ object.";
         s.valid = valid_handle;
+        s.category = "Mouse Interaction";
 
       case "userdata"
         s.doc = "User-defined data to associate with the graphics object.";
@@ -229,6 +247,7 @@
       case "visible"
         s.doc = "If __prop__ is @qcode{\"off\"}, the __objname__ is \
 not rendered on screen.";
+        s.category = "Display";
     endswitch
 
   ## Root properties:
@@ -240,6 +259,7 @@
             "hittest", "interruptible", "selected", ...
             "selectionhighlight", "uicontextmenu", "visible"}
         s.doc = doc_unused;
+        s.category = "Unused";
 
       case "parent"
         s.doc = "Root object has no parent graphics object.  __prop__ \
@@ -247,14 +267,17 @@
 
       case "hittest"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       case "pickableparts"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "callbackobject"
         s.doc = "Graphics handle of the current object whose callback is executing.";
         s.valid = valid_handle;
+        s.category = "Callback Execution";
 
       case "currentfigure"
         s.doc = "Graphics handle of the current figure.";
@@ -263,15 +286,18 @@
       case "diary"
         s.doc = "If __prop__ is @qcode{\"on\"}, the Octave command window \
 session is saved to file.  @xref{XREFrootdiaryfile, , @w{diaryfile property}}.";
+        s.category = "Command Logging";
 
       case "diaryfile"
         s.doc = "The name of the diary file.  \
 @xref{XREFdiary, , @w{diary function}}.";
         s.valid = valid_string;
+        s.category = "Command Logging";
 
       case "echo"
         s.doc = "Control whether Octave displays commands executed from \
 scripts.  @xref{XREFecho, , @w{echo function}}.";
+        s.category = "Command Window Display";
 
       case "errormessage"
         s.doc = "The last error message raised.  \
@@ -280,14 +306,17 @@
 
       case "fixedwidthfontname"
         s.valid = valid_string;
+        s.category = "Command Window Display";
 
       case "format"
         s.doc = "This property is a wrapper around the @code{format} function.\
   @xref{XREFformat, , @w{format function}}.";
+        s.category = "Command Window Display";
 
       case "formatspacing"
         s.doc = "This property is a wrapper around the @code{format} function.\
   @xref{XREFformat, , @w{format function}}.";
+        s.category = "Command Window Display";
 
       case "language"
         s.valid = valid_string;
@@ -295,14 +324,17 @@
       case "monitorpositions"
         s.doc = doc_unused;
         s.printdefault = false;
+        s.category = "Screen Info.";
 
       case "pointerlocation"
         s.doc = doc_unused;
         s.valid = valid_2elvec;
+        s.category = "Pointer Info.";
 
       case "pointerwindow"
         s.doc = doc_unused;
         s.valid = valid_handle;
+        s.category = "Pointer Info.";
 
       case "recursionlimit"
         s.doc = "The maximum number of times a function can be called \
@@ -313,14 +345,17 @@
       case "screendepth"
         s.valid = "double";
         s.printdefault = false;
+        s.category = "Screen Info.";
 
       case "screenpixelsperinch"
         s.valid = "double";
         s.printdefault = false;
+        s.category = "Screen Info.";
 
       case "screensize"
         s.valid = valid_4elvec;
         s.printdefault = false;
+        s.category = "Screen Info.";
 
       case "showhiddenhandles"
         s.doc = "If __prop__ is @qcode{\"on\"}, all graphics objects handles \
@@ -328,6 +363,8 @@
 @code{handlevisibility} property.";
 
       case "units"
+        s.doc = "Units in which screen information are returned."
+        s.category = "Screen Info.";
     endswitch
 
   ## Figure properties
@@ -336,9 +373,11 @@
       ## Overridden shared properties
       case "clipping"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       case "pickableparts"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "alphamap"
@@ -348,22 +387,27 @@
         s.doc = "Function that is executed when a figure is deleted.  \
 @xref{XREFclosereq, , closereq function}.\n\n__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Creation/Deletion";
 
       case "color"
         s.doc = "Color of the figure background.  \
 @xref{Colors, , colorspec}.";
         s.valid = valid_color;
+        s.category = "Appearance";
 
       case "colormap"
         s.doc = "A matrix containing the RGB color map for the current axes.";
         s.valid = "N-by-3 matrix";
+        s.category = "Appearance";
 
       case "currentaxes"
-        s.doc = "Handle to the graphics object of the current axes.";
+        s.doc = "Handle to the graphics object of the current axes.  \
+@xref{XREFgca, , gca function}.";
         s.valid = valid_handle;
 
       case "currentcharacter"
         s.doc = doc_unused;
+        s.category = "Keyboard Interaction";
 
       case "currentobject"
         s.valid = valid_handle;
@@ -384,6 +428,7 @@
 only if the figure's callback @code{windowbuttonmotionfcn} is defined\n\
 @end table";
         s.valid = valid_2elvec;
+        s.category = "Mouse Interaction";
 
       case "dockcontrols"
         s.doc = doc_unused;
@@ -391,21 +436,25 @@
       case "filename"
         s.doc = "The filename used when saving the plot figure.";
         s.valid = valid_string;
+        s.category = "Printing/Saving";
 
       case "graphicssmoothing"
         s.doc = "Use smoothing techniques to reduce the appearance of jagged lines.";
+        s.category = "Appearance";
 
       case "integerhandle"
         s.doc = "Assign the next lowest unused integer as the Figure number.";
 
       case "inverthardcopy"
         s.doc = "Replace the figure and axes background color with white when printing.";
+        s.category = "Printing/Saving";
 
       case "keypressfcn"
         s.doc = "Callback function executed when a keystroke event \
 happens while the figure has focus. The actual key that was pressed \
 can be retrieved using the second argument 'evt' of the function.  __fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Keyboard Interaction";
 
       case "keyreleasefcn"
         s.doc = "With @code{keypressfcn}, the keyboard callback functions.  \
@@ -424,16 +473,19 @@
 @end table\
 \n\n__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Keyboard Interaction";
 
       case "menubar"
         s.doc = "Control the display of the figure menu bar at the top \
 of the figure.";
+        s.category = "Mouse Interaction";
 
       case "name"
         s.doc = "Name to be displayed in the figure title bar.  The name is \
 displayed to the right of any title determined by the @code{numbertitle} \
 property.";
         s.valid = valid_string;
+        s.category = "Appearance";
 
       ## FIXME: Uncomment when support added in graphics.in.h
       #case "number"
@@ -455,6 +507,7 @@
 and width and height of the figure.  \
 @xref{XREFfigureunits, , @w{units property}}.";
         s.valid = valid_4elvec;
+        s.category = "Position";
 
       case "paperorientation"
         s.doc = "The value for the @code{papersize}, and @code{paperposition} \
@@ -462,6 +515,7 @@
 @code{papersize} and @code{paperposition} reverse order \
 when __prop__ is switched between @code{\"portrait\"} and \
 @code{\"landscape\"}.";
+        s.category = "Printing/Saving";
 
       case "paperposition"
         s.doc = "Vector @code{[left bottom width height]} defining the \
@@ -473,6 +527,7 @@
 ignored.  \
 __modemsg__.";
         s.valid = valid_4elvec;
+        s.category = "Printing/Saving";
 
       case "paperpositionmode"
         s.doc = "If __prop__ is set to @qcode{\"auto\"}, the \
@@ -480,6 +535,7 @@
 figure will have the same size as the on-screen figure and will be centered \
 on the output page.  Setting the __prop__ to @code{\"auto\"} does not modify \
 the value of the @code{paperposition} property.";
+        s.category = "Printing/Saving";
 
       case "papersize"
         s.doc = "Vector @code{[width height]} defining the size of the \
@@ -490,6 +546,7 @@
 supported @code{papertype} and consistent with the @code{paperorientation}, \
 the @code{papertype} value is modified to the associated value.";
         s.valid = valid_2elvec;
+        s.category = "Printing/Saving";
 
       case "papertype"
         s.doc = "Name of the paper used for printed output.  \
@@ -501,6 +558,7 @@
 For __prop__ set to @code{\"pixels\"}, the conversion between physical \
 units (ex: @code{\"inches\"}) and @code{\"pixels\"} is dependent on the \
 @code{screenpixelsperinch} property of the root object.";
+        s.category = "Printing/Saving";
 
       case "pointer"
         s.doc = "Name of the mouse pointer shape associated with the canvas \
@@ -509,6 +567,7 @@
 __prop__ has no effect when the figure is in zoom, pan, or rotate mode. \
 In this case, Octave automatically uses a pointer shape appropriate \
 to the mode.";
+        s.category = "Mouse Interaction";
 
       case "pointershapecdata"
         s.doc ="m-by-m matrix defining a custom pointer.  Each \
@@ -516,11 +575,13 @@
 top-left pixel.  A value of 1 is colored black, a value of 2 is colored white, \
 and all other values are rendered as transparent.";
         s.valid = "16-by-16 or 32-by-32 Matrix";
+        s.category = "Mouse Interaction";
 
       case "pointershapehotspot"
         s.doc ="For custom pointers only __prop__ defines the row and column \
 of the pixel in @code{pointershapecdata} that is used as the pointer location.";
         s.valid = valid_2elvec;
+        s.category = "Mouse Interaction";
 
       case "position"
         s.doc = "Specify the position and size of the figure canvas.  \
@@ -528,21 +589,25 @@
 and width and height of the figure.  \
 @xref{XREFfigureunits, , @w{units property}}.";
         s.valid = valid_4elvec;
+        s.category = "Position";
 
       case "renderer"
         s.doc = "Renderering engine used for printing when @code{renderermode} \
 is \"manual\".  __modemsg__.";
+        s.category = "Printing/Saving";
 
       case "renderermode"
         s.doc = "Control whether the renderering engine used for printing is \
 chosen automatically or specified by the @code{renderer} property.  \
 @xref{XREFprint, , @w{print function}}.";
+        s.category = "Printing/Saving";
 
       case "resize"
         s.doc = "Control whether the figure can be resized by dragging the \
 window borders and corners using a mouse.  When __prop__ is @qcode{\"off\"} \
 mouse interactions are disabled but the figure can still be resized by \
 changing its @qcode{\"position\"} property.";
+        s.category = "Mouse Interaction";
 
       case "resizefcn"
         s.doc = "__prop__ is deprecated.  Use @code{sizechangedfcn} instead.";
@@ -562,6 +627,7 @@
 @item open:\n\
 Double Left-click.\n\
 @end table";
+        s.category = "Mouse Interaction";
 
       case "sizechangedfcn"
         s.doc = "Callback triggered when the figure window size is changed.\
@@ -571,20 +637,24 @@
       case "toolbar"
         s.doc = "Control the display of the toolbar (along the bottom of the \
 menubar) and the status bar.  When set to @qcode{\"auto\"}, the display is based on the value of the @code{menubar} property.";
+        s.category = "Mouse Interaction";
 
       case "units"
         s.doc = "The unit used to compute the @code{position} and \
 @code{outerposition} properties.";
+        s.category = "Position";
 
       case "windowbuttondownfcn"
         s.doc = "@xref{XREFfigurewindowbuttonupfcn, , \
 @w{windowbuttonupfcn property}}.";
         s.valid = valid_fcn;
+        s.category = "Mouse Interaction";
 
       case "windowbuttonmotionfcn"
         s.doc = "@xref{XREFfigurewindowbuttonupfcn, , \
 @w{windowbuttonupfcn property}}.";
         s.valid = valid_fcn;
+        s.category = "Mouse Interaction";
 
       case "windowbuttonupfcn"
         s.doc = "With @code{windowbuttondownfcn} and \
@@ -594,16 +664,19 @@
 @code{currentpoint} property holds the current coordinates of the cursor.\
 \n\n__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Mouse Interaction";
 
       case "windowkeypressfcn"
         s.doc = "Function that is executed when a key is pressed and \
 the figure has focus.\n\n__fcnmsg__";
+        s.category = "Keyboard Interaction";
         s.valid = valid_fcn;
 
       case "windowkeyreleasefcn"
         s.doc = "Function that is executed when a key is released and \
 the figure has focus.\n\n__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Keyboard Interaction";
 
       case "windowscrollwheelfcn"
         s.doc = "Function that is executed when a user manipulates \
@@ -622,6 +695,7 @@
 @end table\
 \n\n__fcnmsg__";
         s.valid = valid_fcn;
+        s.category = "Mouse Interaction";
 
       case "windowstyle"
         s.doc = "The window style of a figure.  One of the following values:\n\
@@ -644,6 +718,7 @@
       ## Overridden shared properties
       case "clipping"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "activepositionproperty"
@@ -651,6 +726,7 @@
 @qcode{\"outerposition\"} properties takes precedence when axes \
 annotations extent changes.  @xref{XREFaxesposition, , @w{position property}}, \
 and @ref{XREFaxesposition, , @w{outerposition property}}.";
+        s.category = "Position";
 
       case "alim"
         s.doc = sprintf (doc_notimpl, "Transparency");
@@ -661,31 +737,38 @@
 
       case "box"
         s.doc = "Control whether the axes has a surrounding box.";
+        s.category = "Axes Box Appearance";
 
       case "boxstyle"
         s.doc = "For 3-D axes, control whether the @qcode{\"full\"} \
 box is drawn or only the 3 @qcode{\"back\"} axes";
+        s.category = "Axes Box Appearance";
 
       case "cameraposition"
         s.valid = valid_3elvec;
+        s.category = "Camera Info.";
 
       case "camerapositionmode"
       case "cameratarget"
         s.valid = valid_3elvec;
+        s.category = "Camera Info.";
 
       case "cameratargetmode"
       case "cameraupvector"
         s.valid = valid_3elvec;
+        s.category = "Camera Info.";
 
       case "cameraupvectormode"
       case "cameraviewangle"
         s.valid = "scalar";
+        s.category = "Camera Info.";
 
       case "cameraviewanglemode"
       case "clim"
         s.doc = "Define the limits for the color axis of image children.  \
 __modemsg__.  @xref{XREFpcolor, , @w{pcolor function}}.";
         s.valid = valid_2elvec;
+        s.category = "Camera Info.";
 
       case "climmode"
 
@@ -695,14 +778,17 @@
       case "color"
         s.doc = "Color of the axes background.  @xref{Colors, , colorspec}.";
         s.valid = valid_color;
+        s.category = "Axes Box Appearance";
 
       case "colororder"
         s.doc = "RGB values used by plot function for automatic line \
 coloring.";
         s.valid = "N-by-3 RGB matrix";
+        s.category = "Automatic Line Properties";
 
       case "colororderindex"
         s.doc = doc_unused;
+        s.category = "Automatic Line Properties";
 
       case "currentpoint"
         s.doc = "Matrix @code{[xf, yf, zf; xb, yb, zb]} which holds the \
@@ -714,6 +800,7 @@
 second row the furthest point.  The two points forms a line which is \
 perpendicular to the screen.";
         s.valid = "2-by-3 matrix";
+        s.category = "Mouse Interaction";
 
       case "dataaspectratio"
         s.doc = "Specify the relative height and width of the data \
@@ -722,75 +809,100 @@
 to be the same as the length of 2 units on the y-axis.  \
 @xref{XREFdaspect, , daspect function}.  __modemsg__.";
         s.valid = valid_3elvec;
+        s.category = "Axes Box Appearance";
 
       case "dataaspectratiomode"
+        s.category = "Axes Box Appearance";
       case "fontangle"
         s.doc = doc_fontangle;
+        s.category = "Annotation and Font";
 
       case "fontname"
         s.doc = doc_fontname;
         s.valid = valid_string;
+        s.category = "Annotation and Font";
 
       case "fontsize"
         s.doc = doc_fontsize;
         s.valid = "scalar";
+        s.category = "Annotation and Font";
 
       case "fontsmoothing"
         s.doc = "Control whether any text associated with __objname__ is anti-aliased.";
+        s.category = "Annotation and Font";
 
       case "fontunits"
         s.doc = doc_fontunits;
+        s.category = "Annotation and Font";
 
       case "fontweight"
         s.doc = doc_fontweight;
+        s.category = "Annotation and Font";
 
       case "gridalpha"
         s.doc = sprintf (doc_notimpl, "Transparency");
+        s.category = "Axes Grid Appearance";
 
       case "gridalphamode"
         s.doc = doc_unused;
+        s.category = "Axes Grid Appearance";
 
       case "gridcolor"
         s.doc = doc_unused;
+        s.category = "Axes Grid Appearance";
 
       case "gridcolormode"
         s.doc = doc_unused;
+        s.category = "Axes Grid Appearance";
 
       case "gridlinestyle"
+        s.category = "Axes Grid Appearance";
 
       case "labelfontsizemultiplier"
         s.doc = "Ratio between the x/y/zlabel fontsize and the tick \
 label fontsize";
+        s.category = "Annotation and Font";
 
       case "layer"
         s.doc = "Control whether the axes is drawn below child graphics \
 objects (ticks, labels, etc.@: covered by plotted objects) or above.";
+        s.category = "Axes Box Appearance";
 
       case "linestyleorder"
         s.doc = doc_unused;
+        s.category = "Automatic Line Properties";
 
       case "linestyleorderindex"
         s.doc = doc_unused;
+        s.category = "Automatic Line Properties";
 
       case "linewidth"
         s.doc = "Width of the main axes lines";
+        s.category = "Axes Box Appearance";
 
       case "minorgridalpha"
         s.doc = sprintf (doc_notimpl, "Transparency");
+        s.category = "Axes Grid Appearance";
 
       case "minorgridalphamode"
         s.doc = doc_unused;
+        s.category = "Axes Grid Appearance";
 
       case "minorgridcolor"
         s.doc = doc_unused;
+        s.category = "Axes Grid Appearance";
 
       case "minorgridcolormode"
         s.doc = doc_unused;
+        s.category = "Axes Grid Appearance";
 
       case "minorgridlinestyle"
+        s.category = "Axes Grid Appearance";
+        
       case "mousewheelzoom"
         s.doc = "Fraction of axes limits to zoom for each wheel movement.";
         s.valid = "scalar in the range (0, 1)";
+        s.category = "Mouse Interaction";
 
       case "nextplot"
         s.doc = "__prop__ is used by high level plotting functions to \
@@ -809,12 +921,16 @@
 height to be 0.4 and 0.5 respectively.  \
 @xref{XREFaxesposition, , @w{position property}}.";
         s.valid = valid_4elvec;
+        s.category = "Position";
 
       case "plotboxaspectratio"
         s.doc = "@xref{XREFpbaspect, , pbaspect function}.  \
 __modemsg__.";
+        s.category = "Axes Box Appearance";
 
       case "plotboxaspectratiomode"
+        s.category = "Axes Box Appearance";
+        
       case "position"
         s.doc = "Specify the position of the plot excluding titles, \
 axes, and legend.  The four elements of the vector are the \
@@ -825,6 +941,7 @@
 height to be 0.4 and 0.5 respectively.  \
 @xref{XREFaxesouterposition, , @w{outerposition property}}.";
         s.valid = valid_4elvec;
+        s.category = "Position";
 
       case "projection"
         s.doc = doc_unused;
@@ -835,76 +952,98 @@
       case "tickdir"
         s.doc = "Control whether axes tick marks project \"in\" to the plot \
 box or \"out\".  __modemsg__.";
+        s.category = "Axes Box Appearance";
 
       case "tickdirmode"
+        s.category = "Axes Box Appearance";
 
       case "ticklabelinterpreter"
         s.doc = "Control the way x/y/zticklabel properties are interpreted.\n\
 @xref{XREFinterpreterusage, , @w{Use of the interpreter property}}.";
+        s.category = "Annotation and Font";
 
       case "ticklength"
         s.doc = "Two-element vector @code{[2Dlen 3Dlen]} specifying the \
 length of the tickmarks relative to the longest visible axis.";
         s.valid = valid_2elvec;
+        s.category = "Axes Box Appearance";
 
       case "tightinset"
         s.doc = "Size of the @code{[left bottom right top]} margins \
 around the axes that enclose labels and title annotations.";
         s.valid = valid_4elvec;
         s.printdefault = false;
+        s.category = "Position";
 
       case "title"
         s.doc = "Graphics handle of the title text object.";
         s.valid = valid_handle;
+        s.category = "Annotation and Font";
 
       case "titlefontsizemultiplier"
         s.doc = "Ratio between the title fontsize and the tick \
 label fontsize";
         s.valid = "positive scalar";
+        s.category = "Annotation and Font";
 
       case "titlefontweight"
         s.doc = "Control variant of base font used for the axes title.";
+        s.category = "Annotation and Font";
 
       case "units"
         s.doc = "Units used to interpret the @qcode{\"position\"}, \
 @qcode{\"outerposition\"}, and @qcode{\"tightinset\"} properties.";
+        s.category = "Position";
 
       case "view"
         s.doc = "Two-element vector @code{[azimuth elevation]} specifying \
 the viewpoint for three-dimensional plots";
         s.valid = valid_2elvec;
+        s.category = "Axes Box Appearance";
 
       case "xaxislocation"
         s.doc = "Control the x axis location.";
+        s.category = "Axes Box Appearance";
 
       case "xcolor"
         s.doc = "Color of the x-axis.  @xref{Colors, , colorspec}.  \
 __modemsg__.";
         s.valid = packopt ({markdef(valid_color), "@qcode{\"none\"}"});
+        s.category = "Axes Box Appearance";
 
       case "xcolormode"
+        s.category = "Axes Box Appearance";
 
       case "xdir"
         s.doc = "Direction of the x axis: @qcode{\"normal\"} is left \
 to right.";
+        s.category = "Axes Box Appearance";
 
       case "xgrid"
         s.doc = "Control whether major x grid lines are displayed.";
+        s.category = "Axes Grid Appearance";
 
       case "xlabel"
         s.doc = "Graphics handle of the x label text object.";
         s.valid = valid_handle;
+        s.category = "Annotation and Font";
 
       case "xlim"
         s.doc = "Two-element vector @code{[xmin xmax]} specifying the limits \
 for the x-axis.  __modemsg__.   @xref{XREFxlim, , @w{xlim function}}.";
         s.valid = valid_2elvec;
+        s.category = "Limits";
 
       case "xlimmode"
+        s.category = "Limits";
+        
       case "xminorgrid"
         s.doc = "Control whether minor x grid lines are displayed.";
+        s.category = "Axes Grid Appearance";
 
       case "xminortick"
+        s.category = "Axes Grid Appearance";
+        
       case "xscale"
       case "xtick"
         s.doc = "Position of x tick marks.  __modemsg__.";
@@ -914,95 +1053,141 @@
       case "xticklabel"
         s.doc = "Labels of x tick marks.  __modemsg__.";
         s.valid = valid_cellstring;
+        s.category = "Annotation and Font";
 
       case "xticklabelmode"
+        s.category = "Annotation and Font";
+        
       case "xticklabelrotation"
         s.doc = doc_unused;
+        s.category = "Annotation and Font";
 
       case "xtickmode"
+        s.category = "Annotation and Font";
+        
       case "yaxislocation"
         s.doc = "Control the y-axis location.";
+        s.category = "Axes Box Appearance";
 
       case "ycolor"
         s.doc = "Color of the y-axis.  @xref{Colors, , colorspec}.";
         s.valid = packopt ({markdef(valid_color), "@qcode{\"none\"}"});
+        s.category = "Axes Box Appearance";
 
       case "ycolormode"
+        s.category = "Axes Box Appearance";
 
       case "ydir"
         s.doc = "Direction of the y-axis: @qcode{\"normal\"} is bottom \
 to top.";
+        s.category = "Axes Box Appearance";
 
       case "ygrid"
         s.doc = "Control whether major y grid lines are displayed.";
+        s.category = "Axes Box Appearance";
 
       case "ylabel"
         s.doc = "Graphics handle of the y label text object.";
         s.valid = valid_handle;
+        s.category = "Annotation and Font";
 
       case "ylim"
         s.doc = "Two-element vector @code{[ymin ymax]} specifying the limits \
 for the y-axis.  __modemsg__.  @xref{XREFylim, , @w{ylim function}}.";
         s.valid = valid_2elvec;
+        s.category = "Limits";
 
       case "ylimmode"
+        s.category = "Limits";
+        
       case "yminorgrid"
         s.doc = "Control whether minor y grid lines are displayed.";
+        s.category = "Axes Grid Appearance";
 
       case "yminortick"
+        s.category = "Annotation and Font";
+        
       case "yscale"
+        
       case "ytick"
         s.doc = "Position of y tick marks.  __modemsg__.";
         s.valid = "vector";
         s.printdefault = false;
+        s.category = "Annotation and Font";
 
       case "yticklabel"
         s.doc = "Labels of y tick marks.  __modemsg__.";
         s.valid = valid_cellstring;
+        s.category = "Annotation and Font";
 
       case "yticklabelmode"
+        s.category = "Annotation and Font";
+        
       case "yticklabelrotation"
         s.doc = doc_unused;
+        s.category = "Annotation and Font";
 
       case "ytickmode"
+        s.category = "Annotation and Font";
+        
       case "zcolor"
         s.doc = "Color of the z-axis.  @xref{Colors, , colorspec}.";
         s.valid = packopt ({markdef(valid_color), "@qcode{\"none\"}"});
+        s.category = "Axes Box Appearance";
 
       case "zcolormode"
+        s.category = "Axes Box Appearance";
+        
       case "zdir"
+        s.category = "Axes Box Appearance";
+        
       case "zgrid"
         s.doc = "Control whether major z grid lines are displayed.";
+        s.category = "Axes Grid Appearance";
 
       case "zlabel"
         s.doc = "Graphics handle of the z label text object.";
         s.valid = valid_handle;
+        s.category = "Annotation and Font";
 
       case "zlim"
         s.doc = "Two-element vector @code{[zmin zmaz]} specifying the limits \
 for the z-axis.  __modemsg__.  @xref{XREFzlim, , @w{zlim function}}.";
         s.valid = valid_2elvec;
+        s.category = "Limits";
 
       case "zlimmode"
+        s.category = "Limits";
+        
       case "zminorgrid"
         s.doc = "Control whether minor z grid lines are displayed.";
+        s.category = "Axes Grid Appearance";
 
       case "zminortick"
+        s.category = "Annotation and Font";
+        
       case "zscale"
+        
       case "ztick"
         s.doc = "Position of z tick marks.  __modemsg__.";
         s.valid = "vector";
         s.printdefault = false;
+        s.category = "Annotation and Font";
 
       case "zticklabel"
         s.doc = "Labels of z tick marks.  __modemsg__.";
         s.valid = valid_cellstring;
+        s.category = "Annotation and Font";
 
       case "zticklabelmode"
+        s.category = "Annotation and Font";
+        
       case "zticklabelrotation"
         s.doc = doc_unused;
+        s.category = "Annotation and Font";
 
       case "ztickmode"
+        s.category = "Annotation and Font";
     endswitch
 
   ## Line properties
@@ -1011,74 +1196,90 @@
       ## Overridden shared properties
       case "children"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "color"
         s.doc = "Color of the line object.  @xref{Colors, , colorspec}.";
         s.valid = valid_color;
+        s.category = "Line Appearance";
 
       case "displayname"
         s.doc = "Text for the legend entry corresponding to this line.";
         s.valid = valid_cellstring;
 
       case "interpreter"
+        s.category = "Unused";
 
       case "linestyle"
         s.doc = "@xref{Line Styles}.";
+        s.category = "Line Appearance";
 
       case "linewidth"
         s.doc = "Width of the line object measured in points.";
+        s.category = "Line Appearance";
 
       case "linejoin"
         s.doc = "Control the shape of the junction of line segments. \
 This property currently only affects the printed output.";
+        s.category = "Line Appearance";
 
       case "marker"
         s.doc = "Shape of the marker for each data point.  \
 @xref{Marker Styles}.";
+        s.category = "Marker Appearance";
 
       case "markeredgecolor"
         s.doc = "Color of the edge of the markers.  When set to \
 @qcode{\"auto\"}, the marker edges have the same color as the line.  If set \
 to @qcode{\"none\"}, no marker edges are displayed.  This property can also \
 be set to any color.  @xref{Colors, , colorspec}.";
+        s.category = "Marker Appearance";
 
       case "markerfacecolor"
         s.doc = "Color of the face of the markers.  When set to \
 @qcode{\"auto\"}, the marker faces have the same color as the line.  If set \
 to @qcode{\"none\"}, the marker faces are not displayed.  This property \
 can also be set to any color.  @xref{Colors, , colorspec}.";
+        s.category = "Marker Appearance";
 
       case "markersize"
         s.doc = "Size of the markers measured in points.";
         s.valid = "scalar";
+        s.category = "Marker Appearance";
 
       case "xdata"
         s.doc = "Vector of x data to be plotted.";
         s.valid = "vector";
+        s.category = "Data";
 
       case "xdatasource"
         s.doc = "Name of a vector in the current base workspace to use as \
 x data.";
         s.valid = valid_string;
+        s.category = "Data";
 
       case "ydata"
         s.doc = "Vector of y data to be plotted.";
         s.valid = "vector";
+        s.category = "Data";
 
       case "ydatasource"
         s.doc = "Name of a vector in the current base workspace to use as \
 y data.";
         s.valid = valid_string;
+        s.category = "Data";
 
       case "zdata"
         s.doc = "Vector of z data to be plotted.";
         s.valid = "vector";
+        s.category = "Data";
 
       case "zdatasource"
         s.doc = "Name of a vector in the current base workspace to use as \
 z data.";
         s.valid = valid_string;
+        s.category = "Data";
 
     endswitch
 
@@ -1088,22 +1289,28 @@
       ## Overridden shared properties
       case "children"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "backgroundcolor"
         s.doc = "Color of the background area.  \
 @xref{Colors, , colorspec}.";
         s.valid = valid_color;
+        s.category = "Box Appearance";
 
       case "color"
         s.doc = "Color of the text.  @xref{Colors, ,colorspec}.";
         s.valid = valid_color;
+        s.category = "Text Appearance";
 
       case "displayname"
+        s.category = "Unused";
+        
       case "edgecolor"
         s.doc = "Color of the outline of the background area.  \
 @xref{Colors, , colorspec}.";
         s.valid = valid_color;
+        s.category = "Box Appearance";
 
       case "editing"
         s.doc = doc_unused;
@@ -1113,63 +1320,83 @@
 and location of the text string.";
         s.valid = valid_4elvec;
         s.printdefault = false;
+        s.category = "Position";
 
       case "fontangle"
         s.doc = doc_fontangle;
+        s.category = "Font";
 
       case "fontname"
         s.doc = doc_fontname;
         s.valid = valid_string;
+        s.category = "Font";
 
       case "fontsmoothing"
         s.doc = "Control whether anti-aliasing is used when rendering text.";
+        s.category = "Font";
 
       case "fontsize"
         s.doc = doc_fontsize;
         s.valid = "scalar";
+        s.category = "Font";
 
       case "fontunits"
         s.doc = doc_fontunits;
+        s.category = "Font";
 
       case "fontweight"
         s.doc = doc_fontweight;
+        s.category = "Font";
 
       case "horizontalalignment"
+        s.category = "Position";
+        
       case "interpreter"
         s.doc = "Control the way the @qcode{\"string\"} property is \
 interpreted.\n\
 @xref{XREFinterpreterusage, , @w{Use of the interpreter property}}.";
+        s.category = "Text Appearance";
 
       case "linestyle"
         s.doc = "Style of the outline.  @xref{Line Styles}.";
+        s.category = "Box Appearance";
 
       case "linewidth"
         s.doc = "Width of the outline.";
         s.valid = "scalar";
+        s.category = "Box Appearance";
 
       case "margin"
         s.doc = "Margins between the borders of the background area \
 and the texts.  The value is currently interpreted as pixels, regardless \
 of the @qcode{\"fontunits\"} property.";
         s.valid = "scalar";
+        s.category = "Box Appearance";
 
       case "position"
         s.doc = "Vector @code{[X0 Y0 Z0]} where X0, Y0, and Z0 indicate the \
 position of the text anchor as defined by @code{verticalalignment} and \
 @code{horizontalalignment}.";
         s.valid = valid_3elvec;
+        s.category = "Position";
 
       case "rotation"
         s.doc = "The angle of rotation for the displayed text, \
 measured in degrees.";
         s.valid = "scalar";
+        s.category = "Position";
 
       case "string"
         s.doc = "The text object string content.";
         s.valid = valid_string;
+        s.category = "Text Appearance";
 
       case "units"
+        s.category = "Position";
+        
       case "verticalalignment"
+        s.category = "Position";
+        
     endswitch
 
   ## Image properties
@@ -1178,19 +1405,24 @@
       ## Overridden shared properties
       case "children"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "alphadata"
         s.doc = sprintf (doc_notimpl, "Transparency");
         s.valid = valid_scalmat;
+        s.category = "Data";
 
       case "alphadatamapping"
         s.doc = sprintf (doc_notimpl, "Transparency");
 
       case "cdata"
         s.valid = "matrix";
+        s.category = "Data";
 
       case "cdatamapping"
+        s.category = "Data";
+        
       case "displayname"
         s.doc = "Text for the legend entry corresponding to this image.";
         s.valid = valid_cellstring;
@@ -1202,6 +1434,7 @@
 Setting @code{xdata} to the empty matrix ([]) will restore the default value \
 of @code{[1 columns(image)]}.";
         s.valid = valid_2elvec;
+        s.category = "Data";
 
       case "ydata"
         s.doc = "Two-element vector @code{[yfirst ylast]} specifying the y \
@@ -1210,6 +1443,7 @@
 Setting @code{ydata} to the empty matrix ([]) will restore the default value \
 of @code{[1 rows(image)]}.";
         s.valid = valid_2elvec;
+        s.category = "Data";
 
     endswitch
 
@@ -1219,33 +1453,45 @@
       ## Overridden shared properties
       case "children"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "alphadata"
         s.doc = sprintf (doc_notimpl, "Transparency");
         s.valid = valid_scalmat;
+        s.category = "Data";
 
       case "alphadatamapping"
         s.doc = sprintf (doc_notimpl, "Transparency");
+        s.category = "Data";
 
       case "ambientstrength"
         s.doc = "Strength of the ambient light. Value between 0.0 and 1.0";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "backfacelighting"
         s.doc = "@qcode{\"lit\"}: The normals are used as is for lighting. \
 @qcode{\"reverselit\"}: The normals are always oriented towards the point of view. \
-@qcode{\"unlit\"}: Faces with normals pointing away from the point of view are unlit.";
+@qcode{\"unlit\"}: Faces with normals pointing away from the point of \
+view are unlit.";
+        s.category = "Lighting";
 
       case "cdata"
         s.valid = "matrix";
+        s.category = "Data";
 
       case "cdatamapping"
+        s.category = "Data";
+        
       case "cdatasource"
+        s.category = "Data";
+        
       case "diffusestrength"
         s.doc = "Strength of the diffuse reflex. Value between 0.0 (no \
 diffuse reflex) and 1.0 (full diffuse reflex).";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "displayname"
         s.doc = "Text for the legend entry corresponding to this surface.";
@@ -1253,8 +1499,11 @@
       case "edgealpha"
         s.doc = sprintf (doc_notimpl, "Transparency");
         s.valid = "scalar";
+        s.category = "Outline Appearance";
 
       case "edgecolor"
+        s.category = "Outline Appearance";
+        
       case "edgelighting"
         s.doc = "When set to a value other than @qcode{\"none\"}, the edges \
 of the object are drawn with light and shadow effects.  Supported values are \
@@ -1262,6 +1511,7 @@
 @qcode{\"gouraud\"} (linear interpolation of the lighting effects between \
 the vertices). @qcode{\"phong\"} is deprecated and has the same effect as \
 @qcode{\"gouraud\"}.";
+        s.category = "Lighting";
 
       case "facealpha"
         s.doc = "Transparency level of the faces of the surface object.  Only \
@@ -1275,8 +1525,11 @@
                             "@qcode{\"flat\"}", ...
                             "@qcode{\"interp\"}", ...
                             "@qcode{\"texturemap\"}"});
+        s.category = "Data";
 
       case "facecolor"
+        s.category = "Data";
+        
       case "facelighting"
         s.doc = "When set to a value other than @qcode{\"none\"}, the faces \
 of the object are drawn with light and shadow effects.  Supported values are \
@@ -1284,80 +1537,106 @@
 @qcode{\"gouraud\"} (linear interpolation of the lighting effects between \
 the vertices). @qcode{\"phong\"} is deprecated and has the same effect as \
 @qcode{\"gouraud\"}.";
+        s.category = "Lighting";
 
       case "facenormals"
         s.doc = "Face normals are used for lighting the edges or faces if the \
 @code{edgelighting} or @code{facelighting} properties are set to \
 @qcode{\"flat\"}.  __modemsg__";
+        s.category = "Lighting";
 
       case "facenormalsmode"
         s.doc = "If this property is set to @qcode{\"auto\"}, \
 @code{facenormals} are automatically calculated if the @code{edgelighting} or \
 @code{facelighting} property are set to @qcode{\"flat\"} and at least one \
 @code{light} object is present and visible in the same axes.";
+        s.category = "Lighting";
 
       case "interpreter"
+        s.category = "Unused";
+        
       case "linestyle"
         s.doc = "@xref{Line Styles}.";
+        s.category = "Outline Appearance";
 
       case "linewidth"
         s.doc = "@xref{XREFlinelinewidth, , @w{line linewidth property}}.";
+        s.category = "Outline Appearance";
 
       case "marker"
         s.doc = "@xref{Marker Styles}.";
+        s.category = "Marker Appearance";
 
       case "markeredgecolor"
         s.doc = "@xref{XREFlinemarkeredgecolor, , \
 @w{line markeredgecolor property}}.";
+        s.category = "Marker Appearance";
 
       case "markerfacecolor"
         s.doc = "@xref{XREFlinemarkerfacecolor, , \
 @w{line markerfacecolor property}}.";
+        s.category = "Marker Appearance";
 
       case "markersize"
         s.doc = "@xref{XREFlinemarkersize, , \
 @w{line markersize property}}.";
         s.valid = "scalar";
+        s.category = "Marker Appearance";
 
       case "meshstyle"
+        
       case "specularcolorreflectance"
         s.doc = "Reflectance for specular color. Value between 0.0 (color \
 of underlying face) and 1.0 (color of light source).";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "specularexponent"
         s.doc = "Exponent for the specular reflex. The lower the value, \
 the more the reflex is spread out.";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "specularstrength"
         s.doc = "Strength of the specular reflex. Value between 0.0 (no \
 specular reflex) and 1.0 (full specular reflex).";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "vertexnormals"
         s.doc = "Vertex normals are used for lighting the edges or faces if \
 the @code{edgelighting} or @code{facelighting} properties are set to \
 @qcode{\"gouraud\"}.  __modemsg__";
+        s.category = "Lighting";
 
       case "vertexnormalsmode"
         s.doc = "If this property is set to @qcode{\"auto\"}, \
 @code{vertexnormals} are automatically calculated if the @code{edgelighting} \
 or @code{facelighting} property are set to @qcode{\"gouraud\"} and at least \
 one @code{light} object is present and visible in the same axes.";
+        s.category = "Lighting";
 
       case "xdata"
         s.valid = "matrix";
+        s.category = "Data";
 
       case "xdatasource"
+        s.category = "Data";
+        
       case "ydata"
         s.valid = "matrix";
+        s.category = "Data";
 
       case "ydatasource"
+        s.category = "Data";
+        
       case "zdata"
         s.valid = "matrix";
+        s.category = "Data";
 
       case "zdatasource"
+        s.category = "Data";
+        
     endswitch
 
   ## Patch properties
@@ -1366,19 +1645,23 @@
       ## Overridden shared properties
       case "children"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "alphadatamapping"
         s.doc = sprintf (doc_notimpl, "Transparency");
+        s.category = "Data";
 
       case "ambientstrength"
         s.doc = "Strength of the ambient light. Value between 0.0 and 1.0";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "backfacelighting"
         s.doc =  "@qcode{\"lit\"}: The normals are used as is for lighting. \
 @qcode{\"reverselit\"}: The normals are always oriented towards the point of view. \
 @qcode{\"unlit\"}: Faces with normals pointing away from the point of view are unlit.";
+        s.category = "Lighting";
 
       case "cdata"
         s.doc = "Data defining the patch object color.\n\
@@ -1393,11 +1676,13 @@
 If @code{cdata} is an N-by-M or an N-by-M-by-3 (RGB) matrix, \
 it defines the color at each vertex.";
         s.valid = valid_scalmat;
+        s.category = "Data";
 
       case "diffusestrength"
         s.doc = "Strength of the diffuse reflex. Value between 0.0 (no \
 diffuse reflex) and 1.0 (full diffuse reflex).";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "displayname"
         s.doc = "Text of the legend entry corresponding to this patch.";
@@ -1405,8 +1690,11 @@
       case "edgealpha"
         s.doc = sprintf (doc_notimpl, "Transparency");
         s.valid = valid_scalmat;
+        s.category = "Outline Appearance";
 
       case "edgecolor"
+        s.category = "Outline Appearance";
+        
       case "edgelighting"
         s.doc = "When set to a value other than @qcode{\"none\"}, the edges \
 of the object are drawn with light and shadow effects.  Supported values are \
@@ -1414,6 +1702,7 @@
 @qcode{\"gouraud\"} (linear interpolation of the lighting effects between \
 the vertices). @qcode{\"phong\"} is deprecated and has the same effect as \
 @qcode{\"gouraud\"}.";
+        s.category = "Lighting";
 
       case "facealpha"
         s.doc = "Transparency level of the faces of the patch object.  Only \
@@ -1426,6 +1715,7 @@
         s.valid = packopt ({"scalar", ...
                             "@qcode{\"flat\"}", ...
                             "@qcode{\"interp\"}"});
+        s.category = "Data";
 
       case "facecolor"
         ## Don't provide a default value, and mark colorspec with
@@ -1434,6 +1724,7 @@
                             "@qcode{\"none\"}", ...
                             "@qcode{\"flat\"}", ...
                             "@qcode{\"interp\"}"});
+        s.category = "Data";
 
       case "facelighting"
         s.doc = "When set to a value other than @qcode{\"none\"}, the faces \
@@ -1442,83 +1733,108 @@
 @qcode{\"gouraud\"} (linear interpolation of the lighting effects between \
 the vertices). @qcode{\"phong\"} is deprecated and has the same effect as \
 @qcode{\"gouraud\"}.";
+        s.category = "Lighting";
 
       case "facenormals"
         s.doc = "Face normals are used for lighting the edges or faces if the \
 @code{edgelighting} or @code{facelighting} properties are set to \
 @qcode{\"flat\"}.  __modemsg__";
+        s.category = "Lighting";
 
       case "facenormalsmode"
         s.doc = "If this property is set to @qcode{\"auto\"}, \
 @code{facenormals} are automatically calculated if the @code{edgelighting} or \
 @code{facelighting} property are set to @qcode{\"flat\"} and at least one \
 @code{light} object is present and visible in the same axes.";
+        s.category = "Lighting";
 
       case "faces"
         s.valid = valid_vecmat;
+        s.category = "Data";
 
       case "facevertexalphadata"
         s.doc = sprintf (doc_notimpl, "Transparency");
         s.valid = valid_scalmat;
+        s.category = "Data";
 
       case "facevertexcdata"
+        s.category = "Data";
+        
       case "interpreter"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       case "linestyle"
+        s.category = "Outline Appearance";
+        
       case "linewidth"
+        s.category = "Outline Appearance";
+        
       case "marker"
         s.doc = "@xref{XREFlinemarker, , @w{line marker property}}.";
+        s.category = "Marker Appearance";
 
       case "markeredgecolor"
         s.doc = "@xref{XREFlinemarkeredgecolor, , \
 @w{line markeredgecolor property}}.";
+        s.category = "Marker Appearance";
 
       case "markerfacecolor"
         s.doc = "@xref{XREFlinemarkerfacecolor, , \
 @w{line markerfacecolor property}}.";
+        s.category = "Marker Appearance";
 
       case "markersize"
         s.doc = "@xref{XREFlinemarkersize, , @w{line markersize property}}.";
         s.valid = "scalar";
+        s.category = "Marker Appearance";
 
       case "specularcolorreflectance"
         s.doc = "Reflectance for specular color.  Value between 0.0 (color \
 of underlying face) and 1.0 (color of light source).";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "specularexponent"
         s.doc = "Exponent for the specular reflex.  The lower the value, \
 the more the reflex is spread out.";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "specularstrength"
         s.doc = "Strength of the specular reflex.  Value between 0.0 (no \
 specular reflex) and 1.0 (full specular reflex).";
         s.valid = "scalar";
+        s.category = "Lighting";
 
       case "vertexnormals"
         s.doc = "Vertex normals are used for lighting the edges or faces if \
 the @code{edgelighting} or @code{facelighting} properties are set to \
 @qcode{\"gouraud\"}.  __modemsg__";
+        s.category = "Lighting";
 
       case "vertexnormalsmode"
         s.doc = "If this property is set to @qcode{\"auto\"}, \
 @code{vertexnormals} are automatically calculated if the @code{edgelighting} \
 or @code{facelighting} property are set to @qcode{\"gouraud\"} and at least \
 one @code{light} object is present and visible in the same axes.";
+        s.category = "Lighting";
 
       case "vertices"
         s.valid = valid_vecmat;
+        s.category = "Data";
 
       case "xdata"
         s.valid = valid_vecmat;
+        s.category = "Data";
 
       case "ydata"
         s.valid = valid_vecmat;
+        s.category = "Data";
 
       case "zdata"
         s.valid = valid_vecmat;
+        s.category = "Data";
 
     endswitch
 
@@ -1528,6 +1844,7 @@
       ## Overridden shared properties
       case "children"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "color"
@@ -1550,6 +1867,7 @@
       ## Overridden shared properties
       case "buttondownfcn"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "accelerator"
@@ -1569,6 +1887,7 @@
       ## Overridden shared properties
       case "buttondownfcn"
         s.doc = doc_unused;
+        s.category = "Unused";
 
       ## Specific properties
       case "callback"
@@ -1937,7 +2256,7 @@
         def = strrep (str, "@", "@@");  # must occur first
         def = strrep (def, "{", "@{");
         def = strrep (def, "}", "@}");
-
+        
         def = ["@code{" def "}"];
       else
         args = arrayfun (@(x) num2str (x), size (def), "uniformoutput", false);
@@ -1948,11 +2267,7 @@
 
 endfunction
 
-function str = printdoc (objname, obj)
-  ## Sort fields so that they appear in alphabetic order in the manual
-  fields = sort (fieldnames (obj));
-  nf = numel (fields);
-
+function str = printdoc (objname, obj)  
   ## File header and beginning of properties table
   str = warn_autogen ();
   if (strcmp (objname, "root"))
@@ -1961,43 +2276,60 @@
     str = sprintf ("%s\n\nProperties of @code{%s} objects (@pxref{XREF%s,,%s}):",
                    str, objname, objname, objname);
   endif
-  str = sprintf ("%s\n\n@table @asis", str);
-
-  for ii = 1:nf
-    field = fields{ii};
-    str = sprintf ("%s\n\n", str);
-
-    ## @anchor: cross reference using XREFobjnamefield label
-    ## Concept index: call info from octave with 'doc ("objname field")'
-    str = sprintf ("%s@anchor{XREF%s%s}\n@prindex %s %s\n",
-                   str, objname, field, objname, field);
-
-    ## Item
-    str = sprintf ("%s@item @code{%s}", str, field);
+  
+  ## Sort fields by category, put the special categories "Miscellaneous" and
+  ## "Unused" last. 
+  allfields = fieldnames (obj);
+  allcategories = cellfun (@(s) obj.(s).category, allfields, "uni", false);
+  categories = unique (allcategories);
+  idx = strcmp (categories, "Miscellaneous");
+  categories = [categories(!idx); categories(idx)];
+  idx = strcmp (categories, "Unused");
+  categories = [categories(!idx); categories(idx)];
+  
+  idx = [];
+  for ii = 1:numel (categories)
+    fields = sort (allfields(strcmp (allcategories, categories{ii})));
+    nf = numel (fields);
+    str = sprintf ("%s\n\n@chapheading %s", str, categories{ii});   
+    str = sprintf ("%s\n\n@table @asis", str);
+    
+    for jj = 1:nf
+      field = fields{jj};
+      str = sprintf ("%s\n\n", str);
+      
+      ## @anchor: cross reference using XREFobjnamefield label
+      ## Concept index: call info from octave with 'doc ("objname field")'
+      str = sprintf ("%s@anchor{XREF%s%s}\n@prindex %s %s\n",
+                     str, objname, field, objname, field);
+      
+      ## Item
+      str = sprintf ("%s@item @code{%s}", str, field);
 
-    ## Mark item read-only if needed
-    if (obj.(field).isreadonly)
-      str = sprintf ("%s (read-only):", str);
-    else
-      str = sprintf ("%s:", str);
-    endif
+      ## Mark item read-only if needed
+      if (obj.(field).isreadonly)
+        str = sprintf ("%s (read-only):", str);
+      else
+        str = sprintf ("%s:", str);
+      endif
 
-    ## Print valid and default values
-    tmp = print_options (obj.(field).valid,
-                         obj.(field).default);
-    if (! isempty (tmp))
-      str = sprintf ("%s %s\n", str, tmp);
-    else
-      str = sprintf ("%s\n", str);
-    endif
+      ## Print valid and default values
+      tmp = print_options (obj.(field).valid,
+                           obj.(field).default);
+      if (! isempty (tmp))
+        str = sprintf ("%s %s\n", str, tmp);
+      else
+        str = sprintf ("%s\n", str);
+      endif
 
-    ## Print documentation
-    str = sprintf ("%s%s\n", str, obj.(field).doc);
+      ## Print documentation
+      str = sprintf ("%s%s\n", str, obj.(field).doc);
+    endfor
+
+    ## End of properties table
+    str = sprintf ("%s\n@end table", str);
   endfor
 
-  ## End of properties table
-  str = sprintf ("%s\n@end table", str);
-
 endfunction
 
 function str = warn_autogen ()
