/*
- * Copyright (c) 2021 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2022 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* limitations under the License.
*/
-#include <dali-toolkit/internal/controls/text-controls/text-editor-property-handler.h>
#include <dali-toolkit/internal/controls/text-controls/common-text-utils.h>
+#include <dali-toolkit/internal/controls/text-controls/text-editor-property-handler.h>
#include <dali-toolkit/devel-api/focus-manager/keyinput-focus-manager.h>
}
break;
}
+ case Toolkit::DevelTextEditor::Property::ENABLE_FONT_SIZE_SCALE:
+ {
+ const bool enableFontSizeScale = value.Get<bool>();
+ if(!Equals(impl.mController->IsFontSizeScaleEnabled(), enableFontSizeScale))
+ {
+ impl.mController->SetFontSizeScaleEnabled(enableFontSizeScale);
+ }
+ break;
+ }
case Toolkit::DevelTextEditor::Property::PRIMARY_CURSOR_POSITION:
{
uint32_t position = static_cast<uint32_t>(value.Get<int>());
impl.mRenderer.Reset();
break;
}
+ case Toolkit::DevelTextEditor::Property::STRIKETHROUGH:
+ {
+ const bool update = SetStrikethroughProperties(impl.mController, value, Text::EffectStyle::DEFAULT);
+ if(update)
+ {
+ impl.mRenderer.Reset();
+ }
+ break;
+ }
+ case Toolkit::DevelTextEditor::Property::INPUT_STRIKETHROUGH:
+ {
+ const bool update = SetStrikethroughProperties(impl.mController, value, Text::EffectStyle::INPUT);
+ if(update)
+ {
+ impl.mRenderer.Reset();
+ }
+ break;
+ }
}
}
value = impl.mController->GetLineWrapMode();
break;
}
+ case Toolkit::DevelTextEditor::Property::STRIKETHROUGH:
+ {
+ GetStrikethroughProperties(impl.mController, value, Text::EffectStyle::DEFAULT);
+ break;
+ }
+ case Toolkit::DevelTextEditor::Property::INPUT_STRIKETHROUGH:
+ {
+ GetStrikethroughProperties(impl.mController, value, Text::EffectStyle::INPUT);
+ break;
+ }
case Toolkit::DevelTextEditor::Property::ENABLE_SHIFT_SELECTION:
{
value = impl.mController->IsShiftSelectionEnabled();
value = impl.mController->GetFontSizeScale();
break;
}
+ case Toolkit::DevelTextEditor::Property::ENABLE_FONT_SIZE_SCALE:
+ {
+ value = impl.mController->IsFontSizeScaleEnabled();
+ break;
+ }
case Toolkit::DevelTextEditor::Property::PRIMARY_CURSOR_POSITION:
{
value = static_cast<int>(impl.mController->GetPrimaryCursorPosition());