incubator-ooo-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 119208] Cannot select a different icon set
Date Sun, 15 Apr 2012 17:42:57 GMT
https://issues.apache.org/ooo/show_bug.cgi?id=119208

Ariel Constenla-Haile <arielch@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |arielch@apache.org

--- Comment #6 from Ariel Constenla-Haile <arielch@apache.org> 2012-04-15 17:42:57 UTC
---
The issue is caused because "Tango" has been remove from the listbox string
item list: main/cui/source/options/optgdlg.src#252

    242     ListBox LB_ICONSTYLE
    243     {
    244         HelpID = "cui:ListBox:OFA_TP_VIEW:LB_ICONSTYLE";
    245         Pos = MAP_APPFONT ( 61 , ROW_LB_ICONSIZESTYLE ) ;
    246         Size = MAP_APPFONT ( 65 , 70 ) ;
    247         DropDown = TRUE ;
    248         Border = TRUE ;
    249         TabStop = TRUE ;
    250         StringList [ en-US ] =
    251         {
    252             < "Automatic" ; > ;
    253             < "Galaxy (default)" ; > ;
    254             < "High Contrast" ; > ;
    255             < "Industrial" ; > ;
    256             < "Classic" ; > ;
    257         };
    258     };

but not from the constants in main/vcl/inc/vcl/settings.hxx#485

    485 #define STYLE_SYMBOLS_AUTO        ((sal_uLong)0)
    486 #define STYLE_SYMBOLS_DEFAULT        ((sal_uLong)1)
    487 #define STYLE_SYMBOLS_HICONTRAST    ((sal_uLong)2)
    488 #define STYLE_SYMBOLS_INDUSTRIAL    ((sal_uLong)3)
    489 #define STYLE_SYMBOLS_TANGO        ((sal_uLong)4)
    490 #define STYLE_SYMBOLS_CLASSIC        ((sal_uLong)5)
    491 #define STYLE_SYMBOLS_THEMES_MAX    ((sal_uLong)6)

This way, the listbox has by default 5 items, but STYLE_SYMBOLS_THEMES_MAX is
6; then, in OfaViewTabPage's constructor the array aIconStyleItemId has trash
because it is never initialized, as the condition is false:
main/cui/source/options/optgdlg.cxx#769

    769     if( aIconStyleLB.GetEntryCount() == STYLE_SYMBOLS_THEMES_MAX )
    770     {
    771         // do not check 0th item == auto; it is not a real theme
    772         aIconStyleItemId[0] = 0;
    773         sal_uLong nItem = 1;
    774         for ( sal_uLong n=0; ++n < STYLE_SYMBOLS_THEMES_MAX; )
    775         {
    776             if ( aStyleSettings.CheckSymbolStyle( n ) )
    777             {
    778                 // existing style => save the item id
    779                 aIconStyleItemId[n] = nItem++;
    780             }
    781             else
    782             {
    783                 // non-existing style => remove item;
    784                 aIconStyleLB.RemoveEntry( nItem );
    785                 aIconStyleItemId[n] = 0;
    786             }
    787         }
    788     }

aIconStyleLB.GetEntryCount() == STYLE_SYMBOLS_THEMES_MAX
5 != 6

And then everything else will fail.

-- 
Configure bugmail: https://issues.apache.org/ooo/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

Mime
View raw message