23 , Pad_ { 1 + FrameWidth_ }
25 edit->installEventFilter (
this);
27 const auto markName =
"LC.Core.HasLineEditButtonManager";
30 std::string
str {
"LineEditButtonManager is already installed on the edit" };
32 const auto&
name =
edit->objectName ();
34 str +=
" " +
name.toStdString ();
36 throw std::runtime_error (
str);
49 Edit_->setStyleSheet (
QStringLiteral (
"QLineEdit { padding-right: %1px; }")
57 if (
event->type () == QEvent::Resize ||
58 event->type () == QEvent::Move)
61 return QObject::eventFilter (
obj,
event);
64 void LineEditButtonManager::UpdatePos ()
68 for (
const auto button : Buttons_)
74 const auto&
rect = Edit_->rect ();
75 const int frameWidth = Edit_->style ()->pixelMetric (QStyle::PM_DefaultFrameWidth);
77 (
rect.bottom () + 1 -
hint.height ()) / 2);
Container< T > Filter(const Container< T > &c, F f)