mirror-chatterino2/wordpart.cpp
2017-01-18 13:48:42 +00:00

30 lines
793 B
C++

#include "wordpart.h"
#include "word.h"
WordPart::WordPart(Word &word, int x, int y, const QString &copyText,
bool allowTrailingSpace)
: m_word(word)
, copyText(copyText)
, text(word.isText() ? m_word.getText() : QString())
, x(x)
, y(y)
, width(word.getWidth())
, height(word.getHeight())
, _trailingSpace(word.hasTrailingSpace() & allowTrailingSpace)
{
}
WordPart::WordPart(Word &word, int x, int y, int width, int height,
const QString &copyText, const QString &customText,
bool allowTrailingSpace)
: m_word(word)
, copyText(copyText)
, text(customText)
, x(x)
, y(y)
, width(width)
, height(height)
, _trailingSpace(word.hasTrailingSpace() & allowTrailingSpace)
{
}