22#include <rtl/character.hxx>
29 : m_xEntry(
std::move(pEntry))
30 , m_nAsyncModifyEvent(nullptr)
46 m_nAsyncModifyEvent =
nullptr;
47 m_aModifyHdl.Call(*m_xEntry);
54 if (m_nAsyncModifyEvent)
66 int nStartPos, nEndPos;
67 m_xEntry->get_selection_bounds(nStartPos, nEndPos);
69 m_xEntry->select_region(nStartPos, nEndPos);
74 sal_Int32 nColor = -1;
77 sal_Int32 nLen =
aStr.getLength();
81 static const char*
const pNullStr =
"000000";
82 aStr += OUString::createFromAscii(&pNullStr[nLen - 1]);
96 sal_Int32 nLen = rTest.getLength();
98 OUStringBuffer aFilter(nLen);
99 for (sal_Int32
i = 0;
i < nLen; ++
i)
101 if (rtl::isAsciiHexDigit(*pTest))
102 aFilter.append(*pTest);
106 rTest = aFilter.makeStringAndClear();
static ImplSVEvent * PostUserEvent(const Link< void *, void > &rLink, void *pCaller=nullptr, bool bReferenceLink=false)
static void RemoveUserEvent(ImplSVEvent *nUserEvent)
static bool convertColor(sal_Int32 &rColor, std::u16string_view rValue)
void SetColor(::Color nColor)
std::unique_ptr< weld::Entry > m_xEntry
HexColorControl(std::unique_ptr< weld::Entry > pEdit)
ImplSVEvent * m_nAsyncModifyEvent
constexpr OUStringLiteral sColor
#define LINK(Instance, Class, Member)
IMPL_STATIC_LINK(HexColorControl, ImplProcessInputHdl, OUString &, rTest, bool)
IMPL_LINK_NOARG(CustomWidgetController, DragBeginHdl, weld::DrawingArea &, bool)
std::unique_ptr< char[]> aBuffer