com.jgoodies.forms.debug

Class FormDebugUtils


public final class FormDebugUtils
extends Object

Provides static methods that help you understand and fix layout problems when using the FormLayout. Dumps information about the layout grid, layout groups and cell constraints to the console.

Implicit values are mapped to concrete. For example, implicit alignments in column and row specifications will be visible. And cell constraint alignments that use or override the column and row defaults are visible too.

 ColumnSpec("p")   -> ColumnSpec("fill:pref:0");
 ColumnSpec("p:1") -> ColumnSpec("fill:pref:1");
 
 RowSpec("p")      -> RowSpec("center:pref:0");
 RowSpec("p:1")    -> RowSpec("center:pref:1");
 
Version:
$Revision: 1.5 $
Author:
Karsten Lentzsch
See Also:
FormDebugPanel

Method Summary

static void
dumpAll(Container container)
Dumps all layout state to the console: column and row specifications, column and row groups, grid bounds and cell constraints.
static void
dumpColumnGroups(FormLayout layout)
Dumps the layout's column groups to the console.
static void
dumpColumnSpecs(FormLayout layout)
Dumps the layout's column specifications to the console.
static void
dumpConstraints(Container container)
Dumps the component constraints to the console.
static void
dumpGridBounds(Container container)
Dumps the container's grid info to the console if and only if the container's layout is a FormLayout.
static void
dumpGridBounds(FormLayout.LayoutInfo layoutInfo)
Dumps the grid layout info to the console.
static void
dumpRowGroups(FormLayout layout)
Dumps the layout's row groups to the console.
static void
dumpRowSpecs(FormLayout layout)
Dumps the layout's row specifications to the console.
static FormLayout.LayoutInfo
getLayoutInfo(Container container)
Computes and returns the layout's grid origins.

Method Details

dumpAll

public static void dumpAll(Container container)
Dumps all layout state to the console: column and row specifications, column and row groups, grid bounds and cell constraints.
Parameters:
container - the layout container

dumpColumnGroups

public static void dumpColumnGroups(FormLayout layout)
Dumps the layout's column groups to the console.
Parameters:
layout - the FormLayout to inspect

dumpColumnSpecs

public static void dumpColumnSpecs(FormLayout layout)
Dumps the layout's column specifications to the console.
Parameters:
layout - the FormLayout to inspect

dumpConstraints

public static void dumpConstraints(Container container)
Dumps the component constraints to the console.
Parameters:
container - the layout container to inspect

dumpGridBounds

public static void dumpGridBounds(Container container)
Dumps the container's grid info to the console if and only if the container's layout is a FormLayout.
Parameters:
container - the container to inspect

dumpGridBounds

public static void dumpGridBounds(FormLayout.LayoutInfo layoutInfo)
Dumps the grid layout info to the console.
Parameters:
layoutInfo - provides the column and row origins

dumpRowGroups

public static void dumpRowGroups(FormLayout layout)
Dumps the layout's row groups to the console.
Parameters:
layout - the FormLayout to inspect

dumpRowSpecs

public static void dumpRowSpecs(FormLayout layout)
Dumps the layout's row specifications to the console.
Parameters:
layout - the FormLayout to inspect

getLayoutInfo

public static FormLayout.LayoutInfo getLayoutInfo(Container container)
Computes and returns the layout's grid origins.
Parameters:
container - the layout container to inspect
Returns:
an object that comprises the cell origins and extents

Copyright © 2002-2004 JGoodies Karsten Lentzsch. All Rights Reserved.