mirror-chatterino2/wordpart.cpp

30 lines
793 B
C++
Raw Normal View History

2017-01-11 01:08:20 +01:00
#include "wordpart.h"
#include "word.h"
2017-01-11 18:52:09 +01:00
WordPart::WordPart(Word &word, int x, int y, const QString &copyText,
bool allowTrailingSpace)
2017-01-11 01:08:20 +01:00
: m_word(word)
2017-01-18 04:33:30 +01:00
, copyText(copyText)
, x(x)
, y(y)
, width(word.getWidth())
, height(word.getHeight())
, _trailingSpace(word.hasTrailingSpace() & allowTrailingSpace)
, text(word.isText() ? m_word.getText() : QString())
2017-01-11 01:08:20 +01:00
{
}
2017-01-15 16:38:30 +01:00
WordPart::WordPart(Word &word, int x, int y, int width, int height,
const QString &copyText, const QString &customText,
bool allowTrailingSpace)
: m_word(word)
2017-01-18 04:33:30 +01:00
, copyText(copyText)
, x(x)
, y(y)
, width(width)
, height(height)
, _trailingSpace(word.hasTrailingSpace() & allowTrailingSpace)
, text(customText)
2017-01-11 01:08:20 +01:00
{
}