Is 'choice' and 'group' in UNO possible?

Armin Le Grand armin_le_grand at me.com
Fri Apr 7 09:18:30 UTC 2023


Hi,

On 4/6/23 17:52, Regina Henschel wrote:
> Hi Stephan,
>
> Stephan Bergmann schrieb am 05.04.2023 um 22:19:
>> On 4/5/23 18:47, Regina Henschel wrote:
>>> In RELAX NG (used for ODF file format) the structure below is 
>>> possible. Is something similar possible for to define an 
>>> "enhanced-color" for API? I mean, to have two members, where the 
>>> data type of the second depends on the value of the first.
>>
>> UNO does not support sum types.  So you'd need to resort to something 
>> more ugly, like a struct type with a discriminating member (e.g. an 
>> enum) plus two further members (of which one or the other would be 
>> ignored) or (probably more idiomatic) an ANY.
>>
>
> Then there exist no direct solution. Armin and Tomaž should discuss 
> and tell their ideas to integrate theme colors into multi-color 
> gradients. I would prefer "enum plus two members", but will wait for 
> answers from them.
I have currently an idea about, but no good/complete overview of theme 
colors or their requirements including all possibly involved scenarios 
and since busy with gradients no time to get that, so I hope for Tomaž 
here to have exactly that and give his POV.
>
> Kind regards,
> Regina
>
>
-- 
--
ALG (PGP: EE1C 4B3F E751 D8BC C485 DEC1 3C59 F953 D81C F4A2)



More information about the LibreOffice mailing list