1 30 31 package com.jgoodies.forms.util; 32 33 import com.jgoodies.forms.layout.ConstantSize; 34 import com.jgoodies.forms.layout.Size; 35 import com.jgoodies.forms.layout.Sizes; 36 37 44 45 final class WindowsLayoutStyle extends LayoutStyle { 46 47 static final WindowsLayoutStyle INSTANCE = new WindowsLayoutStyle(); 48 49 private WindowsLayoutStyle() { 50 } 52 53 54 56 private static final Size BUTTON_WIDTH = Sizes.dluX(50); 57 private static final Size BUTTON_HEIGHT = Sizes.dluY(14); 58 59 60 62 private static final ConstantSize DIALOG_MARGIN_X = Sizes.DLUX7; 63 private static final ConstantSize DIALOG_MARGIN_Y = Sizes.DLUY7; 64 65 private static final ConstantSize LABEL_COMPONENT_PADX = Sizes.DLUX3; 66 private static final ConstantSize RELATED_COMPONENTS_PADX = Sizes.DLUX4; 67 private static final ConstantSize RELATED_COMPONENTS_PADY = Sizes.DLUY4; 68 private static final ConstantSize UNRELATED_COMPONENTS_PADX = Sizes.DLUX7; 69 private static final ConstantSize UNRELATED_COMPONENTS_PADY = Sizes.DLUY7; 70 private static final ConstantSize NARROW_LINE_PAD = Sizes.DLUY2; 71 private static final ConstantSize LINE_PAD = Sizes.DLUY3; 72 private static final ConstantSize PARAGRAPH_PAD = Sizes.DLUY9; 73 74 75 77 82 public Size getDefaultButtonWidth() { 83 return BUTTON_WIDTH; 84 } 85 86 91 public Size getDefaultButtonHeight() { 92 return BUTTON_HEIGHT; 93 } 94 95 100 public ConstantSize getDialogMarginX() { 101 return DIALOG_MARGIN_X; 102 } 103 104 109 public ConstantSize getDialogMarginY() { 110 return DIALOG_MARGIN_Y; 111 } 112 113 118 public ConstantSize getLabelComponentPadX() { 119 return LABEL_COMPONENT_PADX; 120 } 121 122 127 public ConstantSize getRelatedComponentsPadX() { 128 return RELATED_COMPONENTS_PADX; 129 } 130 131 136 public ConstantSize getRelatedComponentsPadY() { 137 return RELATED_COMPONENTS_PADY; 138 } 139 140 145 public ConstantSize getUnrelatedComponentsPadX() { 146 return UNRELATED_COMPONENTS_PADX; 147 } 148 149 154 public ConstantSize getUnrelatedComponentsPadY() { 155 return UNRELATED_COMPONENTS_PADY; 156 } 157 158 163 public ConstantSize getLinePad() { 164 return LINE_PAD; 165 } 166 167 172 public ConstantSize getNarrowLinePad() { 173 return NARROW_LINE_PAD; 174 } 175 176 181 public ConstantSize getParagraphPad() { 182 return PARAGRAPH_PAD; 183 } 184 185 } | Popular Tags |