Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Dynamic Interactivity > Control Objects > User Interface Structuring & Layout > Dividers >

Dividers

Dividers
is an option for Grid and related constructs that specifies where and how to draw divider lines.
  • The following basic settings can be given:
Alldraw all dividers
None or Falsedraw no dividers
Truedraw dividers around the exterior only
Centerdraw dividers between interior items only
gdraw all dividers using graphics directive g
  • For Grid and related constructs, lists of settings can be given. Common cases include:
{All, False}put dividers at every horizontal position (column lines)
{False, All}put dividers at every vertical position (row lines)
{{False, True}, False}put a divider before the second column
{False, {False, True}}put a divider before the second row
  • General settings for Dividers in Grid and related constructs can be given as:
{specx,specy}use the at successive x and y positions
  • The can have the following forms:
{s1,s2,...,sn}use through ; then use defaults
{{c}}use c in all cases
{{c1,c2}}alternate between and
{{c1,c2,...}}cycle through all
{s,{c}}use s, then repeatedly use c
{s1,{c},sn}use , then repeatedly use c, but use at the end
{s1,s2,...,{c1,c2,...},sm,...,sn} use the first sequence of at the beginning, then cyclically use the , then use the last sequence of at the end
{s1,s2,...,{},sm,...,sn}use the first sequence of at the beginning and the last sequence at the end
{i1->v1,i2->v2,...}specify what to use at positions
{ spec,rules}use rules to override specifications in spec
  • The and can be True, False, or an explicit graphics directive.
  • Possible graphics directives include Thick, Thin, Dashed, Dotted, as well as color, thickness and dashing directives, and composite directives specified by Directive.
  • For a grid with n items in a particular direction, Dividers can specify settings for dividers in the gaps between items, starting before the first element, and ending after the last element.
  • Dividers are always placed at the center of the gaps between items.
  • Dividers never extend into items that span rows or columns.
Draw all the interior dividers in a grid:
Put dividers at all horizontal positions:
Draw all the interior dividers in a grid:
In[1]:=
Click for copyable input
Out[1]=
 
Put dividers at all horizontal positions:
In[1]:=
Click for copyable input
Out[1]=
Put dividers at the third horizontal and second vertical positions:
Draw a divider at every other horizontal position:
Include the final position:
Draw dividers with specified styles:
Dividers acts in addition to any Frame specification:
FrameStyle will set the default style for all lines in the grid:
New in 6
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF