View Issue Details

IDProjectCategoryView StatusLast Update
0003529NoesisGUIC++ SDKpublic2024-07-29 14:06
ReporterJinFox Assigned Tosfernandez  
PrioritynormalSeverityfeature 
Status assignedResolutionopen 
Product Version3.2.4 
Summary0003529: Support Rich text extension to add support For text content modification (e.g: Lowercase, Uppercase, etc)
Description

Hello,
I was asked to open this ticket to request support to extend Rich Text to be able to add text modifier.

We would like to have a way to add for example tags like :

  • <Lowercase>Example</Lowercase>
  • <Uppercase>Example</Uppercase>,
    Or for example also supporting parameter to those tags like :
    -<ChangeCase Type=CamelCase>Example</ChangeCase>

Currently, a style only approach isn't enough and a parameter only approach prevents tag embedding and isn't the most user friendly when it comes to content designers participation.
Thanks,

PlatformAny

Relationships

related to 0003556 feedbacksfernandez [Feature request] Custom rich text tag supporting both Content and parameters 

Activities

JinFox

JinFox

2024-07-26 12:30

reporter   ~0009834

Hi Sergio,
Thank you for picking up that ticket. Do you have any update on this issue? This new approach to richtext, however great, forces us to change all our text content if we can't get this syntax working the way described in the ticket.
Thanks

maherne

maherne

2024-07-26 13:26

developer   ~0009835

Hi JinFox,

With the Style based approach in Unreal RichText, the only way to modify the contents of a tag is to create a new Span derived class which performs any necessary operations on its child inlines.

I have attached an example of this, a Lowercase Span which will modify it's inlines, changing any Run Text to lowercase.

In order to use this Lowercase Span, you just need to create a Style with a Lowercase TargetType:
<Style x:Key="lowercase" TargetType="{x:Type local:Lowercase}"/>

This Style can then be used in RichText:
Hello this is <lowercase>LOWERCASE TEXT</>!

For your ChangeCase tag, you would create a ChangeCase Span with a Type dependency property, then you would create a Style for each Type:
<Style x:Key="camelcase" TargetType="{x:Type local:ChangeCase}">
<Setter Property="Type" Value="CamelCase"/>
</Style>
<Style x:Key="uppercase" TargetType="{x:Type local:ChangeCase}">
<Setter Property="Type" Value="UpperCase"/>
</Style>

LowercaseSpan.zip (1,720 bytes)
JinFox

JinFox

2024-07-26 14:12

reporter   ~0009837

Hi,
Thanks for this answer. This solution work for lowercase and uppercase example. I will open another ticket to do a request for supporting dynamic modifier like the ChangeCase example.
You can consider this one solved.

Issue History

Date Modified Username Field Change
2024-07-18 14:03 JinFox New Issue
2024-07-19 18:36 jsantos Assigned To => sfernandez
2024-07-19 18:36 jsantos Status new => assigned
2024-07-26 12:30 JinFox Note Added: 0009834
2024-07-26 13:26 maherne Note Added: 0009835
2024-07-26 13:26 maherne File Added: LowercaseSpan.zip
2024-07-26 13:57 maherne Status assigned => feedback
2024-07-26 14:12 JinFox Note Added: 0009837
2024-07-26 14:12 JinFox Status feedback => assigned
2024-07-29 14:06 jsantos Relationship added related to 0003556