anonl / nvlist

@@ -136,14 +136,16 @@
Loading
136 136
        matrixStack.pushMatrix();
137 137
        matrixStack.multiply(trc.transform);
138 138
139 +
        Color tint = new Color();
140 +
        Color.argb8888ToColor(tint, trc.argb);
139 141
        if (!trc.transform.hasShear()) {
140 142
            // For non-rotated text, snap to int coordinates for sharper rendering
141 143
            double tx = getSnapOffset(trc.dx, trc.transform.getTranslationX());
142 144
            double ty = getSnapOffset(trc.dy, trc.transform.getTranslationY());
143 145
            matrixStack.translate(tx, ty);
144 -
            GdxFontUtil.draw(spriteBatch, trc.textLayout, 0, 0, (float)trc.visibleGlyphs);
146 +
            GdxFontUtil.draw(spriteBatch, trc.textLayout, 0, 0, (float)trc.visibleGlyphs, tint);
145 147
        } else {
146 -
            GdxFontUtil.draw(spriteBatch, trc.textLayout, (float)trc.dx, (float)trc.dy, (float)trc.visibleGlyphs);
148 +
            GdxFontUtil.draw(spriteBatch, trc.textLayout, (float)trc.dx, (float)trc.dy, (float)trc.visibleGlyphs, tint);
147 149
        }
148 150
149 151
        matrixStack.popMatrix();

@@ -17,10 +17,10 @@
Loading
17 17
    public final ITextLayout textLayout;
18 18
    public final double visibleGlyphs;
19 19
20 -
    TextRenderCommand(IDrawTransform dt, double dx, double dy, ITextLayout textLayout,
20 +
    TextRenderCommand(IDrawTransform dt, double dx, double dy, int argb, ITextLayout textLayout,
21 21
            double visibleGlyphs) {
22 22
23 -
        super(ID, dt.getZ(), dt.isClipEnabled(), dt.getBlendMode(), 0xFFFFFFFF,
23 +
        super(ID, dt.getZ(), dt.isClipEnabled(), dt.getBlendMode(), argb,
24 24
                (byte)Double.doubleToRawLongBits(dt.getTransform().getTranslationY()));
25 25
26 26
        this.transform = dt.getTransform();

@@ -78,7 +78,7 @@
Loading
78 78
         * isn't flipped if ydir == 1.
79 79
         */
80 80
        double dy = bounds.y - 2 * textLayout.getOffsetY();
81 -
        buffer.drawText(d, dx, dy, textLayout, visibleText);
81 +
        buffer.drawText(d, dx, dy, d.getColorARGB(), textLayout, visibleText);
82 82
    }
83 83
84 84
    private final ITextLayout getLayout() {

@@ -51,10 +51,16 @@
Loading
51 51
        draw(new ScreenshotRenderCommand(ss, clip));
52 52
    }
53 53
54 +
    @Deprecated
54 55
    @Override
55 -
    public void drawText(IDrawTransform dt, double dx, double dy, ITextLayout textLayout,
56 +
    public void drawText(IDrawTransform dt, double dx, double dy, ITextLayout textLayout, double visibleGlyphs) {
57 +
        drawText(dt, dx, dy, 0xFFFFFFFF, textLayout, visibleGlyphs);
58 +
    }
59 +
60 +
    @Override
61 +
    public void drawText(IDrawTransform dt, double dx, double dy, int argb, ITextLayout textLayout,
56 62
            double visibleGlyphs) {
57 -
        draw(new TextRenderCommand(dt, dx, dy, textLayout, visibleGlyphs));
63 +
        draw(new TextRenderCommand(dt, dx, dy, argb, textLayout, visibleGlyphs));
58 64
    }
59 65
60 66
    @Override
Files Complexity Coverage
api/src/main/java/nl/weeaboo/vn 91.53% 96.76%
buildtools/src/main/java/nl/weeaboo/vn/buildtools 83.33% 89.43%
core/src/main/java/nl/weeaboo/vn 82.28% 86.45%
Project Totals (369 files) 83.16% 87.51%
1
codecov:
2
  status:
3
    project: yes
4
    patch: no
Sunburst
The inner-most circle is the entire project, moving away from the center are folders then, finally, a single file. The size and color of each slice is representing the number of statements and the coverage, respectively.
Icicle
The top section represents the entire project. Proceeding with folders and finally individual files. The size and color of each slice is representing the number of statements and the coverage, respectively.
Grid
Each block represents a single file in the project. The size and color of each block is represented by the number of statements and the coverage, respectively.
Loading