raze-gles/source/common/console/c_notifybufferbase.h
Christoph Oelckers 8d3585afe1 - console cleanup.
The bulk of the console is now free of game dependencies.
2020-10-25 13:14:42 +01:00

39 lines
680 B
C++

#pragma once
#include "zstring.h"
#include "tarray.h"
class FFont;
struct FNotifyText
{
int TimeOut;
int Ticker;
int PrintLevel;
FString Text;
};
class FNotifyBufferBase
{
public:
virtual ~FNotifyBufferBase() = default;
virtual void AddString(int printlevel, FString source) = 0;
virtual void Shift(int maxlines);
virtual void Clear();
virtual void Tick();
virtual void Draw() = 0;
protected:
TArray<FNotifyText> Text;
int Top = 0;
int TopGoal = 0;
int LineHeight = 0;
enum { NEWLINE, APPENDLINE, REPLACELINE } AddType = NEWLINE;
void AddString(int printlevel, FFont *printFont, const FString &source, int formatwidth, float keeptime, int maxlines);
};