use of com.jgoodies.forms.layout.FormLayout in project jgnash by ccavanaugh.
the class AbstractCrosstabReport method getReportController.
/**
* Creates a report control panel. May return null if a panel is not used
*
* @return control panel
*/
@Override
public JPanel getReportController() {
FormLayout layout = new FormLayout("p, 4dlu, max(p;45dlu), 8dlu, p, 4dlu, max(p;45dlu), 8dlu, p, 4dlu, p, 8dlu, p, p", "");
DefaultFormBuilder builder = new DefaultFormBuilder(layout);
builder.border(Borders.DIALOG);
builder.append(rb.getString("Label.StartDate"), startDateField);
builder.append(rb.getString("Label.EndDate"), endDateField);
builder.append(rb.getString("Label.Resolution"), resolutionList);
builder.append(refreshButton);
builder.nextLine();
builder.append(rb.getString("Label.SortOrder"), sortOrderList);
builder.append(showLongNamesCheckBox, 4);
builder.append(hideZeroBalanceAccounts, 4);
return builder.getPanel();
}
use of com.jgoodies.forms.layout.FormLayout in project jgnash by ccavanaugh.
the class MonthBalanceCSV method getOptions.
private void getOptions() {
final DatePanel startField = new DatePanel();
final DatePanel endField = new DatePanel();
ButtonGroup group = new ButtonGroup();
JRadioButton vButton = new JRadioButton(rb.getString("Button.Vertical"));
JRadioButton hButton = new JRadioButton(rb.getString("Button.Horizontal"));
group.add(vButton);
group.add(hButton);
vButton.setSelected(true);
FormLayout layout = new FormLayout("right:p, 4dlu, p:g", "");
DefaultFormBuilder builder = new DefaultFormBuilder(layout);
builder.rowGroupingEnabled(true);
builder.append(rb.getString("Label.StartDate"), startField);
builder.append(rb.getString("Label.EndDate"), endField);
builder.append(rb.getString("Label.Layout"), vButton);
builder.append("", hButton);
builder.nextLine();
builder.appendUnrelatedComponentsGapRow();
builder.nextLine();
JPanel panel = builder.getPanel();
int option = JOptionPane.showConfirmDialog(null, new Object[] { panel }, rb.getString("Message.StartEndDate"), JOptionPane.OK_CANCEL_OPTION, JOptionPane.PLAIN_MESSAGE);
if (option == JOptionPane.OK_OPTION) {
startDate = startField.getLocalDate();
endDate = endField.getLocalDate();
}
vertical = vButton.isSelected();
}
use of com.jgoodies.forms.layout.FormLayout in project jgnash by ccavanaugh.
the class AbstractSumByTypeReport method getReportController.
/**
* Creates a report control panel. May return null if a panel is not used
*
* @return control panel
*/
@Override
public JPanel getReportController() {
FormLayout layout = new FormLayout("p, $lcgap, max(p;55dlu), 8dlu, p, $lcgap, max(p;55dlu), 8dlu, p", "");
DefaultFormBuilder builder = new DefaultFormBuilder(layout);
builder.border(Borders.DIALOG);
builder.append(rb.getString("Label.StartDate"), startDateField);
builder.append(rb.getString("Label.EndDate"), endDateField);
builder.append(refreshButton);
builder.nextLine();
builder.append(hideZeroBalanceAccounts, 9);
return builder.getPanel();
}
use of com.jgoodies.forms.layout.FormLayout in project jgnash by ccavanaugh.
the class AccountRegisterReport method createDatePanel.
private JPanel createDatePanel() {
FormLayout layout = new FormLayout("p, $lcgap, max(48dlu;min), 8dlu, p, $lcgap, max(48dlu;min)", "");
DefaultFormBuilder builder = new DefaultFormBuilder(layout);
builder.append(rb.getString("Label.StartDate"), startDateField);
builder.append(rb.getString("Label.EndDate"), endDateField);
return builder.getPanel();
}
use of com.jgoodies.forms.layout.FormLayout in project jgnash by ccavanaugh.
the class AccountRegisterReport method getReportController.
/**
* Creates a report control panel. May return null if a panel is not used
* The ReportController is responsible for dynamic report options with the exception
* of page format options
*
* @return control panel
*/
@Override
public JPanel getReportController() {
FormLayout layout = new FormLayout("p, $lcgap, p:g, 8dlu, p, 8dlu, p", "f:d, $lgap, f:d");
DefaultFormBuilder builder = new DefaultFormBuilder(layout);
builder.border(Borders.DIALOG);
builder.append(rb.getString("Label.Account"), accountCombo);
builder.append(refreshButton, 3);
builder.nextLine();
builder.nextLine();
builder.append(createDatePanel(), 5);
builder.append(detailSplitsCheckBox);
builder.nextLine();
builder.append(createFilterPanel(), 3);
layout.addGroupedRow(1);
layout.addGroupedRow(3);
layout.addGroupedRow(5);
return builder.getPanel();
}
Aggregations