metaforce/Runtime/GuiSys/CSaveableState.hpp

44 lines
1.2 KiB
C++
Raw Normal View History

2018-10-07 03:42:33 +00:00
#pragma once
2016-03-11 00:23:16 +00:00
#include <vector>
#include "Runtime/CToken.hpp"
#include "Runtime/GCNTypes.hpp"
#include "Runtime/GuiSys/CDrawStringOptions.hpp"
#include "Runtime/GuiSys/CGuiTextSupport.hpp"
2020-04-20 01:09:30 +00:00
#include "Runtime/GuiSys/CRasterFont.hpp"
#include <zeus/CColor.hpp>
2016-03-11 00:23:16 +00:00
2021-04-10 08:42:06 +00:00
namespace metaforce {
2018-12-08 05:30:43 +00:00
class CSaveableState {
friend class CColorOverrideInstruction;
friend class CFontInstruction;
friend class CGuiTextSupport;
2018-12-08 05:30:43 +00:00
friend class CLineExtraSpaceInstruction;
friend class CLineSpacingInstruction;
friend class CRemoveColorOverrideInstruction;
friend class CTextExecuteBuffer;
friend class CTextInstruction;
2018-12-08 05:30:43 +00:00
friend class CWordInstruction;
2016-03-19 00:07:31 +00:00
protected:
2018-12-08 05:30:43 +00:00
CDrawStringOptions x0_drawStrOpts;
TLockedToken<CRasterFont> x48_font;
std::vector<CTextColor> x54_colors;
std::vector<bool> x64_colorOverrides;
float x74_lineSpacing = 1.f;
s32 x78_extraLineSpace = 0;
bool x7c_enableWordWrap = false;
EJustification x80_just = EJustification::Left;
EVerticalJustification x84_vjust = EVerticalJustification::Top;
2016-03-11 00:23:16 +00:00
2016-03-19 00:07:31 +00:00
public:
CSaveableState() : x54_colors(3, zeus::skBlack), x64_colorOverrides(16) {}
const TLockedToken<CRasterFont>& GetFont() const { return x48_font; }
2017-01-30 04:16:20 +00:00
2018-12-08 05:30:43 +00:00
bool IsFinishedLoading() const;
2016-03-11 00:23:16 +00:00
};
2021-04-10 08:42:06 +00:00
} // namespace metaforce