#2845 Improve startup time

Branch_+_Trunk
closed-accepted
nobody
GUI (476)
5
2010-10-20
2009-05-07
No

On my WinXP system WinMerge takes over 2 seconds to start, even with a warm cache. This is due to code in BCMenu::GetTransparentBitmap() that loops using GetPixel/SetPixel which is very slow (see http://sourceforge.net/tracker/index.php?func=detail&aid=1052762&group_id=13216&atid=113216 for a similar problem). Attached is a replacement version which uses BitBlt and is much faster. With this my startup time drops to about 0.5s.

I think even more improvement could be possible if the menu icons were all loaded via BCMenu::LoadToolbar() instead of using BCMenu::ModifyODMenu(). This would load a few large bitmap resources instead of many small ones. It would require several toolbars just for this purpose so I'm not sure if it is desirable.

Discussion

  • Kimmo Varis

    Kimmo Varis - 2009-05-07

    Good! Startup time has never bothered me but this kind of improvement is of course very welcome. I'll test this shortly and commit it.

    > It would require several toolbars just for this purpose so
    > I'm not sure if it is desirable
    We want several toolbars anyway - and I think that would be one important GUI improvement.

     
  • Kimmo Varis

    Kimmo Varis - 2009-05-07

    Committed to SVN trunk:
    Completed: At revision: 6717

    Thanks a lot!

     
  • Kimmo Varis

    Kimmo Varis - 2009-05-07
    • milestone: --> 438013
    • status: open --> open-accepted
     
  • Kimmo Varis

    Kimmo Varis - 2009-05-10
    • status: open-accepted --> closed-accepted
     
  • Kimmo Varis

    Kimmo Varis - 2009-05-10

    Closing this item as the patch is in trunk.

     
  • Tim Gerundt

    Tim Gerundt - 2010-10-20

    Backported to branch R2_14 (In Revision 7324)...

     
  • Tim Gerundt

    Tim Gerundt - 2010-10-20
    • milestone: 438013 --> Branch_+_Trunk
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks