Changeset 1258
- Timestamp:
- 03/18/19 18:38:32 (5 years ago)
- Location:
- trunk/src/org
- Files:
-
- 20 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/apollo/gui/ExpandedTrackManager.java
r1102 r1258 170 170 if (!PopupManager.getInstance().isShowing(trackSelectionPopup)) { 171 171 172 trackSelectionPopup.setLocation((DisplayController.getFramePaintArea ().getWidth() - trackSelectionPopup.getFullBounds().getWidth()) / 2, 0);172 trackSelectionPopup.setLocation((DisplayController.getFramePaintAreaWidth() - trackSelectionPopup.getFullBounds().getWidth()) / 2, 0); 173 173 174 174 // Creep from above … … 413 413 assert(Browser._theBrowser != null); 414 414 415 int cpWidth = DisplayController.getFramePaintArea ().getWidth();416 int cpHeight = DisplayController.getFramePaintArea ().getHeight();415 int cpWidth = DisplayController.getFramePaintAreaWidth(); 416 int cpHeight = DisplayController.getFramePaintAreaHeight(); 417 417 if (!DisplayController.isAudienceMode()) { // if message bay is showing - the remove the height 418 418 -
trunk/src/org/apollo/gui/FrameLayoutDaemon.java
r1142 r1258 423 423 // Ensure that left most pixel is at a reasonable position 424 424 if (!supressSpatialLayout && (initiationXPixel < 0 || 425 (initiationXPixel > DisplayController.getFramePaintArea ().getWidth() && DisplayController.getFramePaintArea().getWidth() > leftMargin))) {425 (initiationXPixel > DisplayController.getFramePaintAreaWidth() && DisplayController.getFramePaintAreaWidth() > leftMargin))) { 426 426 initiationXPixel = leftMargin; 427 427 } else if (!supressSpatialLayout && initiationXPixel > LAYOUT_MAX_INITIATION_PIXEL) { … … 432 432 timelineWidth = rightMostPixel - initiationXPixel; 433 433 } else { 434 timelineWidth = DisplayController.getFramePaintArea ().getWidth() - initiationXPixel - rightMargin;434 timelineWidth = DisplayController.getFramePaintAreaWidth() - initiationXPixel - rightMargin; 435 435 } 436 436 … … 546 546 if (width > 0) { 547 547 548 if (width > (DisplayController.getFramePaintArea ().getWidth() - (2 * FREE_SPACE_MARGINS))) {549 width = DisplayController.getFramePaintArea ().getWidth() - (2 * FREE_SPACE_MARGINS);548 if (width > (DisplayController.getFramePaintAreaWidth() - (2 * FREE_SPACE_MARGINS))) { 549 width = DisplayController.getFramePaintAreaWidth() - (2 * FREE_SPACE_MARGINS); 550 550 } 551 551 -
trunk/src/org/expeditee/actions/JfxBrowserActions.java
r1102 r1258 174 174 175 175 // Create widget via text annotation 176 frame.addText(10, 10, "@iw: org.expeditee.items.widgets.JfxBrowser " + (int) (DisplayController.getFramePaintArea ().getWidth() * 0.9) + " "177 + (int) (DisplayController.getFramePaintArea ().getHeight() * 0.9) + " : " + url, null);176 frame.addText(10, 10, "@iw: org.expeditee.items.widgets.JfxBrowser " + (int) (DisplayController.getFramePaintAreaWidth() * 0.9) + " " 177 + (int) (DisplayController.getFramePaintAreaHeight() * 0.9) + " : " + url, null); 178 178 179 179 FrameIO.SaveFrame(frame); -
trunk/src/org/expeditee/actions/Misc.java
r1242 r1258 1239 1239 if(iw instanceof org.expeditee.items.widgets.Browser) { 1240 1240 // Set browser to 'full screen' 1241 iw.setSize(-1, -1, -1, -1, DisplayController.getFramePaintArea ().getWidth(), DisplayController.getFramePaintArea().getHeight() - 80);1241 iw.setSize(-1, -1, -1, -1, DisplayController.getFramePaintAreaWidth(), DisplayController.getFramePaintAreaHeight() - 80); 1242 1242 1243 1243 // If there is a text item attached to cursor use it as url for browser -
trunk/src/org/expeditee/agents/Format.java
r1102 r1258 148 148 + /* item.getX() + */it.getBoundsWidth()); 149 149 150 if (xCheck < DisplayController.getFramePaintArea ().getWidth()) {150 if (xCheck < DisplayController.getFramePaintAreaWidth()) { 151 151 Item columnHead = columnHeads.get(i + 1); 152 152 if (columnHead.getX() < maxX && columnHead.getY() < maxY) { -
trunk/src/org/expeditee/auth/Authenticator.java
r1254 r1258 191 191 secret_key = (SecretKey) keyStore.getKey(label, password_ca); 192 192 } catch (final UnrecoverableEntryException e) { 193 e.printStackTrace(); 193 194 secret_key = null; 194 195 } -
trunk/src/org/expeditee/auth/gui/MailBay.java
r1243 r1258 216 216 private static void updateLink() { 217 217 if (!isLinkInitialized && DisplayController.getFramePaintArea() != null 218 && DisplayController.getFramePaintArea ().getWidth() > 0) {218 && DisplayController.getFramePaintAreaWidth() > 0) { 219 219 // set up 'Messages' link on the right hand side 220 220 _mailLink.setPosition(DisplayController.getMessageBayPaintArea().getWidth() - MAIL_LINK_Y_OFFSET, … … 231 231 Text t = new Text("You have [" + _messages.size() + "] unprocessed messages waiting. Two latest below:"); 232 232 t.setPosition(OFFSET_X, HEADER_OFFSET_Y); 233 t.setOffset(0, -DisplayController.getFramePaintArea ().getHeight());233 t.setOffset(0, -DisplayController.getFramePaintAreaHeight()); 234 234 t.setColor(fontColor); 235 235 t.setFont(_messageFont.clone()); -
trunk/src/org/expeditee/core/bounds/AxisAlignedBoxBounds.java
r1149 r1258 5 5 import org.expeditee.core.Line; 6 6 import org.expeditee.core.Point; 7 import org.expeditee.gui.DisplayController; 7 8 8 9 /** -
trunk/src/org/expeditee/gio/gesture/StandardGestureActions.java
r1242 r1258 1370 1370 NumberFormat nf = Vector.getNumberFormatter(); 1371 1371 linker.setText(linker.getText() + ": " 1372 + nf.format((width / DisplayController.getFramePaintArea ().getWidth())));1372 + nf.format((width / DisplayController.getFramePaintAreaWidth()))); 1373 1373 } else { 1374 1374 linker.setText(linker.getText() + ": " + width); … … 2218 2218 FrameUtils.Align(column, false, 0); 2219 2219 // Check if it will be outside the frame area 2220 if (dummyItem.getY() < 0 || dummyItem.getY() > DisplayController.getFramePaintArea ().getHeight()) {2220 if (dummyItem.getY() < 0 || dummyItem.getY() > DisplayController.getFramePaintAreaHeight()) { 2221 2221 // Check for the 'next' tag! 2222 2222 Frame current = DisplayController.getCurrentFrame(); … … 2278 2278 if (dummyItem.getText().length() == 0 || FreeItems.hasItemsAttachedToCursor()) { 2279 2279 dummyItem.getParentOrCurrentFrame().removeItem(dummyItem); 2280 dummyItem.setRightMargin(DisplayController.getFramePaintArea ().getWidth(), false);2280 dummyItem.setRightMargin(DisplayController.getFramePaintAreaWidth(), false); 2281 2281 } else { 2282 2282 dummyItem.setWidth(toDropFrom.getWidth()); -
trunk/src/org/expeditee/gui/DisplayController.java
r1245 r1258 73 73 public static final int MINIMUM_FRAME_HEIGHT = 512; 74 74 75 p rivatestatic boolean DISPLAYED_ABOVE_MINIMUM_FRAME_WIDTH = false;75 public static boolean DISPLAYED_ABOVE_MINIMUM_FRAME_WIDTH = false; 76 76 77 77 /** Convenience definition of TwinFramesSide.LEFT. */ … … 1245 1245 } 1246 1246 1247 public static Dimension getSizeEnforceMinimum () {1248 Dimension actual_dim = getFramePaintArea ().getSize();1247 public static Dimension getSizeEnforceMinimumXXXX() { // **** DB 1248 Dimension actual_dim = getFramePaintAreaSize(); 1249 1249 1250 1250 int enforced_width = Math.max(actual_dim.width, MINIMUM_FRAME_WIDTH); … … 1305 1305 } 1306 1306 1307 public static int getFramePaintAreaWidth() 1308 { 1309 if (!DISPLAYED_ABOVE_MINIMUM_FRAME_WIDTH) { 1310 return MINIMUM_FRAME_WIDTH; 1311 } 1312 1313 return _framePaintArea.getWidth(); 1314 } 1315 1316 public static int getFramePaintAreaHeight() 1317 { 1318 if (!DISPLAYED_ABOVE_MINIMUM_FRAME_WIDTH) { 1319 return MINIMUM_FRAME_HEIGHT; 1320 } 1321 1322 return _framePaintArea.getHeight(); 1323 } 1324 1325 public static Dimension getFramePaintAreaSize() 1326 { 1327 if (!DISPLAYED_ABOVE_MINIMUM_FRAME_WIDTH) { 1328 Dimension min_dim = new Dimension(MINIMUM_FRAME_WIDTH,MINIMUM_FRAME_HEIGHT); 1329 return min_dim; 1330 } 1331 1332 return _framePaintArea.getSize(); 1333 } 1334 1307 1335 public static AxisAlignedBoxBounds getMessageBayPaintArea() 1308 1336 { … … 1407 1435 Image image = null; 1408 1436 if (currentFrame != null && (!useInvalidation || !frameClip.isFullyClipped())) { 1409 image = FrameGraphics.getFrameImage(currentFrame, frameClip, getFramePaintArea ().getSize());1437 image = FrameGraphics.getFrameImage(currentFrame, frameClip, getFramePaintAreaSize()); 1410 1438 } 1411 1439 -
trunk/src/org/expeditee/gui/FrameCreator.java
r1102 r1258 220 220 // new frame 221 221 if (!_multiColumn 222 || toAdd.getBoundsWidth() + _lastX > DisplayController.getFramePaintArea ().getWidth()) {222 || toAdd.getBoundsWidth() + _lastX > DisplayController.getFramePaintAreaWidth()) { 223 223 // Make sure text items that are created on the current 224 224 // frame are removed … … 231 231 toAdd.setOffset(0, 0); 232 232 toAdd.setID(_current.getNextItemID()); 233 toAdd.setRightMargin(DisplayController.getFramePaintArea ().getWidth(), true);233 toAdd.setRightMargin(DisplayController.getFramePaintAreaWidth(), true); 234 234 235 235 _current.addItem(toAdd); -
trunk/src/org/expeditee/gui/MessageBay.java
r1221 r1258 133 133 private static void updateLink() { 134 134 if (!isLinkInitialized && DisplayController.getFramePaintArea() != null 135 && DisplayController.getFramePaintArea ().getWidth() > 0) {135 && DisplayController.getFramePaintAreaWidth() > 0) { 136 136 // set up 'Messages' link on the right hand side 137 137 _messageLink.setPosition(DisplayController.getMessageBayPaintArea().getWidth() - MESSAGE_LINK_Y_OFFSET, … … 218 218 Text t = new Text(getMessagePrefix(true) + message); 219 219 t.setPosition(20, 15 + _messages.size() * 25); 220 t.setOffset(0, -DisplayController.getFramePaintArea ().getHeight());220 t.setOffset(0, -DisplayController.getFramePaintAreaHeight()); 221 221 t.setColor(color); 222 222 t.setLink(link); -
trunk/src/org/expeditee/io/PDF2Writer.java
r1144 r1258 147 147 148 148 public PDF2Writer() { 149 _pageSize = DisplayController.getFramePaintArea ().getSize();149 _pageSize = DisplayController.getFramePaintAreaSize(); 150 150 _pdfDocument = new Document(new Rectangle(_pageSize.width, _pageSize.height)); 151 151 } -
trunk/src/org/expeditee/io/PdfFramesetWriter.java
r1102 r1258 67 67 { 68 68 super(firstFrame, maxFrame); 69 Dimension d = DisplayController.getFramePaintArea ().getSize();69 Dimension d = DisplayController.getFramePaintAreaSize(); 70 70 _pdfDocument = new Document(new Rectangle(d.width, d.height)); 71 71 _showFrameNames = showFrameNames; … … 185 185 FrameGraphics.getMaxSize().height);*/ 186 186 GraphicsManager g = EcosystemManager.getGraphicsManager(); 187 Image temp = EcosystemManager.getImageManager().createImage(DisplayController.getFramePaintArea ().getSize());187 Image temp = EcosystemManager.getImageManager().createImage(DisplayController.getFramePaintAreaSize()); 188 188 lineEnd.paint(); 189 189 // if (fill != null) { … … 202 202 { 203 203 PdfContentByte cb = _pdfWriter.getDirectContent(); 204 Graphics2D g = cb.createGraphicsShapes(DisplayController.getFramePaintArea ().getWidth(), DisplayController.getFramePaintArea().getHeight());205 Image temp = EcosystemManager.getImageManager().createImage(DisplayController.getFramePaintArea ().getSize());204 Graphics2D g = cb.createGraphicsShapes(DisplayController.getFramePaintAreaWidth(), DisplayController.getFramePaintAreaHeight()); 205 Image temp = EcosystemManager.getImageManager().createImage(DisplayController.getFramePaintAreaSize()); 206 206 EcosystemManager.getGraphicsManager().pushDrawingSurface(temp); 207 207 toWrite.paint(); … … 214 214 { 215 215 PdfContentByte cb = _pdfWriter.getDirectContent(); 216 Graphics2D g = cb.createGraphicsShapes(DisplayController.getFramePaintArea ().getWidth(), DisplayController.getFramePaintArea().getHeight());217 Image temp = EcosystemManager.getImageManager().createImage(DisplayController.getFramePaintArea ().getSize());216 Graphics2D g = cb.createGraphicsShapes(DisplayController.getFramePaintAreaWidth(), DisplayController.getFramePaintAreaHeight()); 217 Image temp = EcosystemManager.getImageManager().createImage(DisplayController.getFramePaintAreaSize()); 218 218 EcosystemManager.getGraphicsManager().pushDrawingSurface(temp); 219 219 toWrite.paint(); -
trunk/src/org/expeditee/io/WebParser.java
r1125 r1258 302 302 try { 303 303 304 final int verticalScrollPerPage = (int) (DisplayController.getFramePaintArea ().getHeight() * 0.85);305 final int horizontalScrollPerPage = (int) (DisplayController.getFramePaintArea ().getWidth() * 0.85);304 final int verticalScrollPerPage = (int) (DisplayController.getFramePaintAreaHeight() * 0.85); 305 final int horizontalScrollPerPage = (int) (DisplayController.getFramePaintAreaWidth() * 0.85); 306 306 307 307 Platform.runLater(new Runnable() { -
trunk/src/org/expeditee/items/Dot.java
r1102 r1258 117 117 int oldX = getX(); 118 118 if (anchor != null) { 119 float deltaX = DisplayController.getFramePaintArea ().getWidth() - anchor - getBoundsWidth() - oldX;119 float deltaX = DisplayController.getFramePaintAreaWidth() - anchor - getBoundsWidth() - oldX; 120 120 121 121 anchorConnected(AnchorEdgeType.Right, deltaX); … … 160 160 int oldY = getY(); 161 161 if (anchor != null) { 162 float deltaY = DisplayController.getFramePaintArea ().getHeight() - anchor - getBoundsHeight() - oldY;162 float deltaY = DisplayController.getFramePaintAreaHeight() - anchor - getBoundsHeight() - oldY; 163 163 anchorConnected(AnchorEdgeType.Bottom, deltaY); 164 164 } -
trunk/src/org/expeditee/items/Item.java
r1244 r1258 1379 1379 { 1380 1380 final Bounds bounds = AxisAlignedBoxBounds.getEnclosing(this.getBoundingBox()); 1381 Dimension frameSize = DisplayController.getFramePaintArea ().getSize();1381 Dimension frameSize = DisplayController.getFramePaintAreaSize(); 1382 1382 1383 1383 int x = bounds.getMaxX(); -
trunk/src/org/expeditee/items/Text.java
r1245 r1258 387 387 if (width == null) { 388 388 setJustification(Justification.left); 389 setRightMargin(DisplayController.getFramePaintArea ().getWidth(), false);389 setRightMargin(DisplayController.getFramePaintAreaWidth(), false); 390 390 return; 391 391 } … … 402 402 if (width == null) { 403 403 setJustification(Justification.left); 404 setRightMargin(DisplayController.getFramePaintArea ().getWidth(), false);404 setRightMargin(DisplayController.getFramePaintAreaWidth(), false); 405 405 return; 406 406 } … … 1801 1801 if (limitWidth) { 1802 1802 if (_maxWidth == null) { 1803 width = DisplayController.getFramePaintArea ().getWidth() - getX();1803 width = DisplayController.getFramePaintAreaWidth() - getX(); 1804 1804 } else { 1805 1805 width = getAbsoluteWidth(); … … 2282 2282 int model_frame_name_x = modelFrame.getNameItem().getX(); 2283 2283 if (model_frame_name_x < DisplayController.MINIMUM_FRAME_WIDTH) { 2284 System.err.println(" Text::resetTitlePostion(): value to be used as right margin from position of frameName < 512");2284 System.err.println("**** Text::resetTitlePostion(): value to be used as right margin from position of frameName < 512"); 2285 2285 System.err.println(" Overriding to ensure reasonable width for title"); 2286 2286 model_frame_name_x = DisplayController.MINIMUM_FRAME_WIDTH; … … 2395 2395 private void clipFrameMargin() { 2396 2396 if (!hasFixedWidth()) { 2397 int frameWidth = DisplayController.getFramePaintArea ().getWidth();2397 int frameWidth = DisplayController.getFramePaintAreaWidth(); 2398 2398 /* 2399 2399 * Only change width if it is more than 150 pixels from the right of the screen … … 2417 2417 } 2418 2418 2419 Integer width = DisplayController.getFramePaintArea ().getWidth();2419 Integer width = DisplayController.getFramePaintAreaWidth(); 2420 2420 2421 2421 // Check if that text item is inside an enclosing rectangle... … … 2457 2457 2458 2458 public void resetFrameNamePosition() { 2459 Dimension maxSize = DisplayController.getSizeEnforceMinimum(); 2460 2459 //Dimension maxSize = DisplayController.getSizeEnforceMinimum(); 2460 Dimension maxSize = DisplayController.getFramePaintAreaSize(); 2461 2461 2462 if (maxSize != null) { 2462 2463 // setMaxWidth(maxSize.width); … … 2717 2718 // Subtract off the link width 2718 2719 if (anchor != null) { 2719 setX(DisplayController.getFramePaintArea ().getWidth() - anchor - getBoundsWidth() + getLeftMargin());2720 setX(DisplayController.getFramePaintAreaWidth() - anchor - getBoundsWidth() + getLeftMargin()); 2720 2721 } 2721 2722 return; … … 2728 2729 int oldX = getX(); 2729 2730 if (anchor != null) { 2730 float deltaX = DisplayController.getFramePaintArea ().getWidth() - anchor - getBoundsWidth()2731 float deltaX = DisplayController.getFramePaintAreaWidth() - anchor - getBoundsWidth() 2731 2732 + getLeftMargin() - oldX; 2732 2733 anchorConnected(AnchorEdgeType.Right, deltaX); … … 2778 2779 final float ascent = getTextLayouts().get(0).getAscent(); 2779 2780 final float descent = getTextLayouts().get(0).getDescent(); 2780 setY(DisplayController.getFramePaintArea ().getHeight()2781 setY(DisplayController.getFramePaintAreaHeight() 2781 2782 - (anchor + this.getBoundsHeight() - ascent - descent)); 2782 2783 } else if (this.getFont() != null) { … … 2785 2786 final float ascent = fakeLayout.getAscent(); 2786 2787 final float descent = fakeLayout.getDescent(); 2787 setY(DisplayController.getFramePaintArea ().getHeight()2788 setY(DisplayController.getFramePaintAreaHeight() 2788 2789 - (anchor + this.getBoundsHeight() - ascent - descent)); 2789 2790 } … … 2800 2801 if (anchor != null) { 2801 2802 2802 float deltaY = DisplayController.getFramePaintArea ().getHeight() - anchor - oldY;2803 float deltaY = DisplayController.getFramePaintAreaHeight() - anchor - oldY; 2803 2804 anchorConnected(AnchorEdgeType.Bottom, deltaY); 2804 2805 } -
trunk/src/org/expeditee/items/XRayable.java
r1102 r1258 290 290 _source.setAnchorBottom(anchor); 291 291 if (anchor != null) 292 _source.setY(DisplayController.getFramePaintArea ().getHeight() - getHeight() - anchor);292 _source.setY(DisplayController.getFramePaintAreaHeight() - getHeight() - anchor); 293 293 } 294 294 … … 302 302 public void setAnchorRight(Integer anchor) { 303 303 _source.setAnchorRight(anchor); 304 _source.setX(DisplayController.getFramePaintArea ().getWidth() - anchor - this.getWidth());304 _source.setX(DisplayController.getFramePaintAreaWidth() - anchor - this.getWidth()); 305 305 } 306 306 -
trunk/src/org/expeditee/items/widgets/Widget.java
r1177 r1258 1825 1825 1826 1826 if (anchor != null) { 1827 setPositions(_d2, DisplayController.getFramePaintArea ().getWidth() - anchor, _d2.getY());1827 setPositions(_d2, DisplayController.getFramePaintAreaWidth() - anchor, _d2.getY()); 1828 1828 invalidateSelf(); 1829 1829 } … … 1857 1857 1858 1858 if (anchor != null) { 1859 setPositions(_d3, _d3.getX(), DisplayController.getFramePaintArea ().getHeight() - anchor);1859 setPositions(_d3, _d3.getX(), DisplayController.getFramePaintAreaHeight() - anchor); 1860 1860 invalidateSelf(); 1861 1861 }
Note:
See TracChangeset
for help on using the changeset viewer.