36 std::optional<BtQmlInterface::Selection>
const & selection,
39 , m_workLabel(new QLabel(this))
41 , m_firstKeyLabel(new QLabel(this))
42 , m_lastKeyLabel(new QLabel(this))
43 , m_sizeTooLargeLabel(new QLabel(this))
44 , m_buttonBox(new QDialogButtonBox(QDialogButtonBox::Ok
45 | QDialogButtonBox::Cancel, this))
49 auto *
const vLayout =
new QVBoxLayout(
this);
51 auto *
const formLayout =
new QFormLayout();
52 formLayout->setHorizontalSpacing(15);
53 formLayout->setVerticalSpacing(15);
54 formLayout->setContentsMargins(11, 11, 11, 16);
55 vLayout->addLayout(formLayout);
59 for (
auto const *
const m : modules)
63 static_cast<void const *
>(m))));
69 auto const parentKey = parent->
swordKey();
76 auto *
const hLayout =
new QHBoxLayout;
77 vLayout->addLayout(hLayout);
91 if (selection.has_value()) {
92 BT_ASSERT(selection->column < modules.size());
99 auto const handleKeyChanged = [
this, model]{
120 userData.value<
void *>());
124 this, &BtCopyByReferencesDialog::reject);
Model that represents the entire text of a given module.
CSwordKey * indexToKey(int index, int moduleNum) const
int keyToIndex(CSwordKey const &key) const