void Controller::SetMarkupProcessorEnabled( bool enable )
{
- mImpl->mMarkupProcessorEnabled = enable;
+ if( enable != mImpl->mMarkupProcessorEnabled )
+ {
+ //If Text was already set, call the SetText again for enabling or disabling markup
+ mImpl->mMarkupProcessorEnabled = enable;
+ std::string text;
+ GetText( text );
+ SetText( text );
+ }
}
bool Controller::IsMarkupProcessorEnabled() const
return mImpl->mModel->mVerticalAlignment;
}
+bool Controller::IsIgnoreSpacesAfterText() const
+{
+ return mImpl->mModel->mIgnoreSpacesAfterText;
+}
+
+void Controller::SetIgnoreSpacesAfterText( bool ignore )
+{
+ mImpl->mModel->mIgnoreSpacesAfterText = ignore;
+}
+
+bool Controller::IsMatchSystemLanguageDirection() const
+{
+ return mImpl->mModel->mMatchSystemLanguageDirection;
+}
+
+void Controller::SetMatchSystemLanguageDirection( bool match )
+{
+ mImpl->mModel->mMatchSystemLanguageDirection = match;
+}
+
+void Controller::SetLayoutDirection( Dali::LayoutDirection::Type layoutDirection )
+{
+ mImpl->mLayoutDirection = layoutDirection;
+}
+
+
void Controller::SetLineWrapMode( Text::LineWrap::Mode lineWrapMode )
{
if( lineWrapMode != mImpl->mModel->mLineWrapMode )
// public : Relayout.
-Controller::UpdateTextType Controller::Relayout( const Size& size )
+Controller::UpdateTextType Controller::Relayout( const Size& size, Dali::LayoutDirection::Type layoutDirection )
{
DALI_LOG_INFO( gLogFilter, Debug::Verbose, "-->Controller::Relayout %p size %f,%f, autoScroll[%s]\n", this, size.width, size.height, mImpl->mIsAutoScrollEnabled ?"true":"false" );
UpdateTextType updateTextType = NONE_UPDATED;
+ mImpl->mLayoutDirection = layoutDirection;
if( ( size.width < Math::MACHINE_EPSILON_1000 ) || ( size.height < Math::MACHINE_EPSILON_1000 ) )
{
if( 0u != mImpl->mModel->mVisualModel->mGlyphPositions.Count() )
totalNumberOfGlyphs,
mImpl->mModel->mHorizontalAlignment,
mImpl->mModel->mLineWrapMode,
- outlineWidth );
+ outlineWidth,
+ mImpl->mModel->mIgnoreSpacesAfterText,
+ mImpl->mModel->mMatchSystemLanguageDirection );
// Resize the vector of positions to have the same size than the vector of glyphs.
Vector<Vector2>& glyphPositions = mImpl->mModel->mVisualModel->mGlyphPositions;
requestedNumberOfCharacters,
mImpl->mModel->mHorizontalAlignment,
lines,
- mImpl->mModel->mAlignmentOffset );
+ mImpl->mModel->mAlignmentOffset,
+ mImpl->mLayoutDirection,
+ mImpl->mModel->mMatchSystemLanguageDirection );
viewUpdated = true;
}