jTracer  1.03
Stack trace visualization tool
JPanel org.libcsdbg.jtracer.TraceBar.createField ( String  nm)
private

Create one of the fields.

Parameters
[in]nmthe field name
Returns
the created field

Definition at line 159 of file TraceBar.java.

References org.libcsdbg.jtracer.Registry.get().

160  {
161  GridBagLayout lm = new GridBagLayout();
162  GridBagConstraints c = new GridBagConstraints();
163  JPanel retval = new JPanel(lm);
164 
165  Registry conf = Registry.getCurrent();
166  retval.setBackground((Color) conf.get("statusbar", "bgcolor"));
167  retval.setBorder(BorderFactory.createEtchedBorder(EtchedBorder.LOWERED));
168 
169  JLabel field = new JLabel("n/a");
170  field.setFont((Font) conf.get("statusbar", "font"));
171  field.setForeground((Color) conf.get("statusbar", "fgcolor"));
172 
173  if (nm.equals("message")) {
174  c.weightx = 1;
175  c.anchor = GridBagConstraints.EAST;
176  }
177 
178  c.insets = new Insets(1, 8, 1, 8);
179  lm.setConstraints(field, c);
180  retval.add(field);
181 
182  fields.put(nm, field);
183  return retval;
184  }

+ Here is the call graph for this function: