mirror of
https://github.com/bancika/diy-layout-creator
synced 2026-11-11 01:32:08 +10:00
sil ic alpha rendering
This commit is contained in:
Binary file not shown.
@@ -97,6 +97,7 @@ public class SIL_IC extends AbstractTransparentComponent<String> {
|
||||
public SIL_IC() {
|
||||
super();
|
||||
updateControlPoints();
|
||||
alpha = 100;
|
||||
}
|
||||
|
||||
@EditableProperty
|
||||
@@ -282,13 +283,6 @@ public class SIL_IC extends AbstractTransparentComponent<String> {
|
||||
return;
|
||||
}
|
||||
Area mainArea = getBody()[0];
|
||||
Composite oldComposite = g2d.getComposite();
|
||||
if (alpha < MAX_ALPHA) {
|
||||
g2d.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 1f * alpha / MAX_ALPHA));
|
||||
}
|
||||
g2d.setColor(outlineMode ? Constants.TRANSPARENT_COLOR : getBodyColor());
|
||||
g2d.fill(mainArea);
|
||||
g2d.setComposite(oldComposite);
|
||||
|
||||
if (!outlineMode) {
|
||||
int pinSize = (int) PIN_SIZE.convertToPixels() / 2 * 2;
|
||||
@@ -300,6 +294,14 @@ public class SIL_IC extends AbstractTransparentComponent<String> {
|
||||
}
|
||||
}
|
||||
|
||||
Composite oldComposite = g2d.getComposite();
|
||||
if (alpha < MAX_ALPHA) {
|
||||
g2d.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER, 1f * alpha / MAX_ALPHA));
|
||||
}
|
||||
g2d.setColor(outlineMode ? Constants.TRANSPARENT_COLOR : getBodyColor());
|
||||
g2d.fill(mainArea);
|
||||
g2d.setComposite(oldComposite);
|
||||
|
||||
Color finalBorderColor;
|
||||
if (outlineMode) {
|
||||
Theme theme =
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user