https://bugs.documentfoundation.org/show_bug.cgi?id=157034

--- Comment #2 from Regina Henschel <[email protected]> ---
(In reply to Julien Nabet from comment #1)

> With this patch, it seems to work:
> diff --git a/svx/source/tbxctrls/PaletteManager.cxx
> b/svx/source/tbxctrls/PaletteManager.cxx
> index 9b8f144f66b0..77cbab82207d 100644
> --- a/svx/source/tbxctrls/PaletteManager.cxx
> +++ b/svx/source/tbxctrls/PaletteManager.cxx
> @@ -161,7 +161,10 @@ bool PaletteManager::IsThemePaletteSelected() const
>  
>  bool PaletteManager::GetThemeAndEffectIndex(sal_uInt16 nItemId, sal_uInt16&
> rThemeIndex, sal_uInt16& rEffectIndex)
>  {
> -     // Each column is the same color with different effects.
> +    // tdf#157034, nItemId begins with 1 but list of themes begin with 0
> +    // so decrement nItemId
> +    --nItemId;
> +    // Each column is the same color with different effects.
>      rThemeIndex = nItemId % 12;
>  
>      rEffectIndex = nItemId / 12;
> 
> Regina: does it seem to you?

Yes, that looks correct. Do you want to write the fix? If yes, please set Tomaž
Vajngerl for review.

Do you have an idea for a unit test? Likely something with dispatcher. But
without further research I couldn't write a test.

BTW, the error is visible in export to pptx as well.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to