Commit 709e9ac8 authored by Drahomír Karchňák's avatar Drahomír Karchňák

New test result banner.

parent ab644367
......@@ -8,13 +8,9 @@ import java.awt.RenderingHints;
import java.awt.image.BufferedImage;
import java.io.IOException;
/**
* Created by bcx on 1/30/18.
*/
public class ForumBannerGenerator extends AbstractImageGenerator {
private static final int BANNER_WIDTH = 560;
private static final int BANNER_HEIGHT = 300;
private static final int BANNER_HEIGHT = 274;
private static final String TEMPLATE_FORMAT = "forumbanner_%s.png";
......@@ -67,17 +63,17 @@ public class ForumBannerGenerator extends AbstractImageGenerator {
prepareFonts();
renderTemplate(lang, finalImageGraphics);
renderMainValue(formatNumber(download, lang), 93, 132, finalImageGraphics);
renderMainValue(formatNumber(upload, lang), 280, 132, finalImageGraphics);
renderMainValue(formatNumber(ping, lang), 469, 132, finalImageGraphics);
renderMainValue(formatNumber(download, lang), 93, 118, finalImageGraphics);
renderMainValue(formatNumber(upload, lang), 280, 118, finalImageGraphics);
renderMainValue(formatNumber(ping, lang), 469, 118, finalImageGraphics);
renderAdditionalValue(isp, AdditionalValuePositionMapping.getFirstColumnX(lang), 246, finalImageGraphics);
renderAdditionalValue(typ, AdditionalValuePositionMapping.getFirstColumnX(lang), 278, finalImageGraphics);
renderAdditionalValue(signal, AdditionalValuePositionMapping.getSecondColumnX(lang), 246, finalImageGraphics);
renderAdditionalValue(os, AdditionalValuePositionMapping.getSecondColumnX(lang), 278, finalImageGraphics);
renderAdditionalValue(isp, AdditionalValuePositionMapping.getFirstColumnX(lang), 219, finalImageGraphics);
renderAdditionalValue(typ, AdditionalValuePositionMapping.getFirstColumnX(lang), 254, finalImageGraphics);
renderAdditionalValue(signal, AdditionalValuePositionMapping.getSecondColumnX(lang), 219, finalImageGraphics);
renderAdditionalValue(os, AdditionalValuePositionMapping.getSecondColumnX(lang), 254, finalImageGraphics);
renderTimeDateValue(formattedTime, 550, 16, finalImageGraphics);
renderTimeDateValue(formattedDate, 550, 40, finalImageGraphics);
renderTimeDateValue(formattedDate, 550, 16, finalImageGraphics);
renderTimeDateValue(formattedTime, 550, 40, finalImageGraphics);
return finalImage;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment