src/java.desktop/share/classes/javax/swing/text/ParagraphView.java

Print this page




1167          *
1168          * @return the inset
1169          */
1170         protected short getLeftInset() {
1171             View parentView;
1172             int adjustment = 0;
1173             if ((parentView = getParent()) != null) { //use firstLineIdent for the first row
1174                 if (this == parentView.getView(0)) {
1175                     adjustment = firstLineIndent;
1176                 }
1177             }
1178             return (short)(super.getLeftInset() + adjustment);
1179         }
1180 
1181         protected short getBottomInset() {
1182             return (short)(super.getBottomInset() +
1183                            ((minorRequest != null) ? minorRequest.preferred : 0) *
1184                            lineSpacing);
1185         }
1186 
1187         final static int SPACE_ADDON = 0;
1188         final static int SPACE_ADDON_LEFTOVER_END = 1;
1189         final static int START_JUSTIFIABLE = 2;
1190         //this should be the last index in justificationData
1191         final static int END_JUSTIFIABLE = 3;
1192 
1193         int justificationData[] = null;
1194     }
1195 
1196 }


1167          *
1168          * @return the inset
1169          */
1170         protected short getLeftInset() {
1171             View parentView;
1172             int adjustment = 0;
1173             if ((parentView = getParent()) != null) { //use firstLineIdent for the first row
1174                 if (this == parentView.getView(0)) {
1175                     adjustment = firstLineIndent;
1176                 }
1177             }
1178             return (short)(super.getLeftInset() + adjustment);
1179         }
1180 
1181         protected short getBottomInset() {
1182             return (short)(super.getBottomInset() +
1183                            ((minorRequest != null) ? minorRequest.preferred : 0) *
1184                            lineSpacing);
1185         }
1186 
1187         static final int SPACE_ADDON = 0;
1188         static final int SPACE_ADDON_LEFTOVER_END = 1;
1189         static final int START_JUSTIFIABLE = 2;
1190         //this should be the last index in justificationData
1191         static final int END_JUSTIFIABLE = 3;
1192 
1193         int justificationData[] = null;
1194     }
1195 
1196 }