Use more space
This commit is contained in:
		@ -8,10 +8,10 @@
 | 
			
		||||
#include <mvp/View.hpp>
 | 
			
		||||
#include <gui/driverview_screen/DriverViewPresenter.hpp>
 | 
			
		||||
#include <touchgfx/widgets/Box.hpp>
 | 
			
		||||
#include <touchgfx/containers/Container.hpp>
 | 
			
		||||
#include <touchgfx/containers/progress_indicators/LineProgress.hpp>
 | 
			
		||||
#include <touchgfx/widgets/canvas/PainterRGB565.hpp>
 | 
			
		||||
#include <touchgfx/widgets/TextArea.hpp>
 | 
			
		||||
#include <touchgfx/containers/Container.hpp>
 | 
			
		||||
#include <gui/containers/Temperature.hpp>
 | 
			
		||||
#include <touchgfx/widgets/canvas/Line.hpp>
 | 
			
		||||
#include <touchgfx/containers/scrollers/ScrollWheel.hpp>
 | 
			
		||||
@ -69,6 +69,7 @@ protected:
 | 
			
		||||
     * Member Declarations
 | 
			
		||||
     */
 | 
			
		||||
    touchgfx::Box __background;
 | 
			
		||||
    touchgfx::Container SoC;
 | 
			
		||||
    touchgfx::LineProgress tsSoC;
 | 
			
		||||
    touchgfx::PainterRGB565 tsSoCPainter;
 | 
			
		||||
    touchgfx::LineProgress lvSoC;
 | 
			
		||||
 | 
			
		||||
@ -7,21 +7,21 @@
 | 
			
		||||
 | 
			
		||||
DriverViewFieldBase::DriverViewFieldBase()
 | 
			
		||||
{
 | 
			
		||||
    setWidth(150);
 | 
			
		||||
    setWidth(152);
 | 
			
		||||
    setHeight(80);
 | 
			
		||||
    box.setPosition(0, 0, 150, 80);
 | 
			
		||||
    box.setPosition(0, 0, 152, 80);
 | 
			
		||||
    box.setColor(touchgfx::Color::getColorFromRGB(0, 0, 0));
 | 
			
		||||
    box.setBorderColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    box.setBorderSize(3);
 | 
			
		||||
    add(box);
 | 
			
		||||
 | 
			
		||||
    title.setPosition(0, 0, 150, 25);
 | 
			
		||||
    title.setPosition(0, 0, 152, 25);
 | 
			
		||||
    title.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    title.setLinespacing(0);
 | 
			
		||||
    title.setTypedText(touchgfx::TypedText(T_DRIVERVIEWFIELD_TITLE));
 | 
			
		||||
    add(title);
 | 
			
		||||
 | 
			
		||||
    value.setPosition(0, 20, 150, 57);
 | 
			
		||||
    value.setPosition(0, 20, 152, 57);
 | 
			
		||||
    value.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    value.setLinespacing(0);
 | 
			
		||||
    value.setTypedText(touchgfx::TypedText(T_NUMBERWILDCARD));
 | 
			
		||||
 | 
			
		||||
@ -7,19 +7,19 @@
 | 
			
		||||
 | 
			
		||||
DriverViewFieldSelectionBase::DriverViewFieldSelectionBase()
 | 
			
		||||
{
 | 
			
		||||
    setWidth(150);
 | 
			
		||||
    setWidth(152);
 | 
			
		||||
    setHeight(26);
 | 
			
		||||
    bg.setPosition(0, 0, 150, 25);
 | 
			
		||||
    bg.setPosition(0, 0, 152, 25);
 | 
			
		||||
    bg.setColor(touchgfx::Color::getColorFromRGB(34, 34, 34));
 | 
			
		||||
    add(bg);
 | 
			
		||||
 | 
			
		||||
    name.setPosition(0, 0, 150, 25);
 | 
			
		||||
    name.setPosition(0, 0, 152, 25);
 | 
			
		||||
    name.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    name.setLinespacing(0);
 | 
			
		||||
    name.setTypedText(touchgfx::TypedText(T_DRIVERVIEWFIELD_TITLE));
 | 
			
		||||
    add(name);
 | 
			
		||||
 | 
			
		||||
    line1.setPosition(0, 25, 150, 1);
 | 
			
		||||
    line1.setPosition(0, 25, 152, 1);
 | 
			
		||||
    line1Painter.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    line1.setPainter(line1Painter);
 | 
			
		||||
    line1.setStart(0, 0);
 | 
			
		||||
@ -37,7 +37,7 @@ DriverViewFieldSelectionBase::DriverViewFieldSelectionBase()
 | 
			
		||||
    line2.setLineEndingStyle(touchgfx::Line::ROUND_CAP_ENDING);
 | 
			
		||||
    add(line2);
 | 
			
		||||
 | 
			
		||||
    line2_1.setPosition(149, 0, 1, 26);
 | 
			
		||||
    line2_1.setPosition(151, 0, 1, 26);
 | 
			
		||||
    line2_1Painter.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    line2_1.setPainter(line2_1Painter);
 | 
			
		||||
    line2_1.setStart(0, 0);
 | 
			
		||||
 | 
			
		||||
@ -7,21 +7,21 @@
 | 
			
		||||
 | 
			
		||||
ErrorPopupBase::ErrorPopupBase()
 | 
			
		||||
{
 | 
			
		||||
    setWidth(450);
 | 
			
		||||
    setWidth(456);
 | 
			
		||||
    setHeight(150);
 | 
			
		||||
    bg.setPosition(0, 0, 450, 150);
 | 
			
		||||
    bg.setPosition(0, 0, 456, 150);
 | 
			
		||||
    bg.setColor(touchgfx::Color::getColorFromRGB(197, 14, 31));
 | 
			
		||||
    bg.setBorderColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    bg.setBorderSize(5);
 | 
			
		||||
    add(bg);
 | 
			
		||||
 | 
			
		||||
    title.setPosition(0, 0, 450, 49);
 | 
			
		||||
    title.setPosition(0, 0, 456, 49);
 | 
			
		||||
    title.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    title.setLinespacing(0);
 | 
			
		||||
    title.setTypedText(touchgfx::TypedText(T___SINGLEUSE_1NKF));
 | 
			
		||||
    add(title);
 | 
			
		||||
 | 
			
		||||
    details.setPosition(15, 60, 420, 75);
 | 
			
		||||
    details.setPosition(17, 60, 426, 75);
 | 
			
		||||
    details.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    details.setLinespacing(0);
 | 
			
		||||
    details.setTypedText(touchgfx::TypedText(T___SINGLEUSE_9L8R));
 | 
			
		||||
 | 
			
		||||
@ -16,7 +16,8 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
    __background.setColor(touchgfx::Color::getColorFromRGB(0, 0, 0));
 | 
			
		||||
    add(__background);
 | 
			
		||||
 | 
			
		||||
    tsSoC.setXY(15, 155);
 | 
			
		||||
    SoC.setPosition(12, 125, 152, 180);
 | 
			
		||||
    tsSoC.setXY(0, 25);
 | 
			
		||||
    tsSoC.setProgressIndicatorPosition(0, 0, 40, 150);
 | 
			
		||||
    tsSoC.setRange(0, 100);
 | 
			
		||||
    tsSoC.setBackground(touchgfx::Bitmap(BITMAP_BAT_BAR_BG_ID));
 | 
			
		||||
@ -27,9 +28,9 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
    tsSoC.setLineWidth(100);
 | 
			
		||||
    tsSoC.setLineEndingStyle(touchgfx::Line::BUTT_CAP_ENDING);
 | 
			
		||||
    tsSoC.setValue(60);
 | 
			
		||||
    add(tsSoC);
 | 
			
		||||
    SoC.add(tsSoC);
 | 
			
		||||
 | 
			
		||||
    lvSoC.setXY(110, 155);
 | 
			
		||||
    lvSoC.setXY(95, 25);
 | 
			
		||||
    lvSoC.setProgressIndicatorPosition(0, 0, 40, 150);
 | 
			
		||||
    lvSoC.setRange(0, 100);
 | 
			
		||||
    lvSoC.setBackground(touchgfx::Bitmap(BITMAP_BAT_BAR_BG_ID));
 | 
			
		||||
@ -40,21 +41,23 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
    lvSoC.setLineWidth(100);
 | 
			
		||||
    lvSoC.setLineEndingStyle(touchgfx::Line::BUTT_CAP_ENDING);
 | 
			
		||||
    lvSoC.setValue(80);
 | 
			
		||||
    add(lvSoC);
 | 
			
		||||
    SoC.add(lvSoC);
 | 
			
		||||
 | 
			
		||||
    tsSoCLabel.setPosition(15, 130, 40, 25);
 | 
			
		||||
    tsSoCLabel.setPosition(0, 0, 40, 25);
 | 
			
		||||
    tsSoCLabel.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    tsSoCLabel.setLinespacing(0);
 | 
			
		||||
    tsSoCLabel.setTypedText(touchgfx::TypedText(T___SINGLEUSE_PHFD));
 | 
			
		||||
    add(tsSoCLabel);
 | 
			
		||||
    SoC.add(tsSoCLabel);
 | 
			
		||||
 | 
			
		||||
    lvSoCLabel.setPosition(110, 130, 40, 25);
 | 
			
		||||
    lvSoCLabel.setPosition(95, 0, 40, 25);
 | 
			
		||||
    lvSoCLabel.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    lvSoCLabel.setLinespacing(0);
 | 
			
		||||
    lvSoCLabel.setTypedText(touchgfx::TypedText(T___SINGLEUSE_4OBM));
 | 
			
		||||
    add(lvSoCLabel);
 | 
			
		||||
    SoC.add(lvSoCLabel);
 | 
			
		||||
 | 
			
		||||
    drivetrainTemps.setPosition(315, 130, 150, 175);
 | 
			
		||||
    add(SoC);
 | 
			
		||||
 | 
			
		||||
    drivetrainTemps.setPosition(316, 125, 152, 180);
 | 
			
		||||
    motorTempLabel.setPosition(0, 90, 150, 25);
 | 
			
		||||
    motorTempLabel.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    motorTempLabel.setLinespacing(0);
 | 
			
		||||
@ -99,7 +102,7 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
 | 
			
		||||
    add(drivetrainTemps);
 | 
			
		||||
 | 
			
		||||
    brakeTemps.setPosition(165, 130, 150, 150);
 | 
			
		||||
    brakeTemps.setPosition(164, 125, 152, 150);
 | 
			
		||||
    btDivVert.setPosition(74, 25, 3, 123);
 | 
			
		||||
    btDivVertPainter.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    btDivVert.setPainter(btDivVertPainter);
 | 
			
		||||
@ -138,8 +141,8 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
 | 
			
		||||
    add(brakeTemps);
 | 
			
		||||
 | 
			
		||||
    dataFields.setPosition(15, 48, 450, 257);
 | 
			
		||||
    fieldTypeSelection.setPosition(0, 80, 150, 177);
 | 
			
		||||
    dataFields.setPosition(12, 43, 456, 257);
 | 
			
		||||
    fieldTypeSelection.setPosition(0, 80, 152, 177);
 | 
			
		||||
    fieldTypeSelection.setHorizontal(false);
 | 
			
		||||
    fieldTypeSelection.setCircular(true);
 | 
			
		||||
    fieldTypeSelection.setEasingEquation(touchgfx::EasingEquations::linearEaseOut);
 | 
			
		||||
@ -153,10 +156,10 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
    fieldTypeSelection.setVisible(false);
 | 
			
		||||
    dataFields.add(fieldTypeSelection);
 | 
			
		||||
 | 
			
		||||
    field3.setXY(300, 0);
 | 
			
		||||
    field3.setXY(304, 0);
 | 
			
		||||
    dataFields.add(field3);
 | 
			
		||||
 | 
			
		||||
    field2.setXY(150, 0);
 | 
			
		||||
    field2.setXY(152, 0);
 | 
			
		||||
    dataFields.add(field2);
 | 
			
		||||
 | 
			
		||||
    field1.setXY(0, 0);
 | 
			
		||||
@ -164,24 +167,20 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
 | 
			
		||||
    add(dataFields);
 | 
			
		||||
 | 
			
		||||
    statusBar.setPosition(15, 15, 450, 33);
 | 
			
		||||
    statusBar.setPosition(12, 10, 456, 33);
 | 
			
		||||
    statusItems.setXY(0, 0);
 | 
			
		||||
    statusItems.setDirection(touchgfx::EAST);
 | 
			
		||||
    statusTS_R2D.setXY(0, 0);
 | 
			
		||||
    statusItems.add(statusTS_R2D);
 | 
			
		||||
 | 
			
		||||
    statusItems.add(statusTS_R2D);
 | 
			
		||||
 | 
			
		||||
    statusItems.add(statusAMS);
 | 
			
		||||
 | 
			
		||||
    statusSDC.setXY(150, 0);
 | 
			
		||||
    statusItems.add(statusSDC);
 | 
			
		||||
 | 
			
		||||
    statusSCS.setXY(225, 0);
 | 
			
		||||
    statusItems.add(statusSCS);
 | 
			
		||||
 | 
			
		||||
    statusItems.add(statusPDU);
 | 
			
		||||
 | 
			
		||||
    statusINV.setXY(375, 0);
 | 
			
		||||
    statusItems.add(statusINV);
 | 
			
		||||
 | 
			
		||||
    statusBar.add(statusItems);
 | 
			
		||||
@ -196,21 +195,21 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
    progressBar.setVisible(false);
 | 
			
		||||
    statusBar.add(progressBar);
 | 
			
		||||
 | 
			
		||||
    prechargeLabel.setXY(90, -2);
 | 
			
		||||
    prechargeLabel.setXY(95, -2);
 | 
			
		||||
    prechargeLabel.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    prechargeLabel.setLinespacing(0);
 | 
			
		||||
    prechargeLabel.setTypedText(touchgfx::TypedText(T___SINGLEUSE_HMH2));
 | 
			
		||||
    prechargeLabel.setVisible(false);
 | 
			
		||||
    statusBar.add(prechargeLabel);
 | 
			
		||||
 | 
			
		||||
    r2dLabel.setPosition(67, -2, 317, 37);
 | 
			
		||||
    r2dLabel.setPosition(70, -2, 317, 37);
 | 
			
		||||
    r2dLabel.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    r2dLabel.setLinespacing(0);
 | 
			
		||||
    r2dLabel.setTypedText(touchgfx::TypedText(T___SINGLEUSE_NGUK));
 | 
			
		||||
    r2dLabel.setVisible(false);
 | 
			
		||||
    statusBar.add(r2dLabel);
 | 
			
		||||
 | 
			
		||||
    r2dProgressLabel.setPosition(165, -2, 219, 37);
 | 
			
		||||
    r2dProgressLabel.setPosition(168, -2, 219, 37);
 | 
			
		||||
    r2dProgressLabel.setColor(touchgfx::Color::getColorFromRGB(255, 255, 255));
 | 
			
		||||
    r2dProgressLabel.setLinespacing(0);
 | 
			
		||||
    r2dProgressLabel.setTypedText(touchgfx::TypedText(T___SINGLEUSE_J5UH));
 | 
			
		||||
@ -219,7 +218,7 @@ DriverViewViewBase::DriverViewViewBase() :
 | 
			
		||||
 | 
			
		||||
    add(statusBar);
 | 
			
		||||
 | 
			
		||||
    errorPopup.setXY(15, 155);
 | 
			
		||||
    errorPopup.setXY(12, 150);
 | 
			
		||||
    errorPopup.setVisible(false);
 | 
			
		||||
    add(errorPopup);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user