Ignore:
Timestamp:
11/19/20 13:41:28 (3 years ago)
Author:
bnemhaus
Message:

Expeditee now respects the users antialiasing setting. The previous system

  1. Attempted to respect antialiasing by checking the setting and enabling it if the setting was true
  2. In the process of painting the frame some special items (link marks etc) want to use antialiasing reguardless of setting. This was achieved by turning antialiasing on, doing the thing and then turning it off. This unfortunately meant that, in the scenario that the users antialiasing setting is on, it gets turned off after drawing one of these special items and doesn't get turn on again until all items have been drawn.

The new system still always turns antialiasing on for these special items, but instead of turning it off after, it returns it to the setting it was previously on. This is achieved with two new functions: setTransientAntialiasingOn() and setTransientAntialiasingOff().

On a related note, there was also an issue with some polygons being drawn with a thickness of 0.0f, which was causing them to antialias badly. They now have a thickness of 1.0f.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/expeditee/items/Line.java

    r1541 r1545  
    535535                GraphicsManager g = EcosystemManager.getGraphicsManager();
    536536               
    537                 g.setAntialiasing(true);
     537                g.setTransientAntialiasingOn();
    538538                g.drawPolygon(arrow.close(), null, null, 0.0f, arrowFill, arrowColour, arrowStroke);
    539                 g.setAntialiasing(false);
     539                g.setTransientAntialiasingOff();
    540540        }
    541541
Note: See TracChangeset for help on using the changeset viewer.