Developer forums (C::B DEVELOPMENT STRICTLY!) > Contributions to C::B

BOUNTY: Notebook class with "close" button at the right

(1/35) > >>

rickg22:
OK Guys. I think the solution's much easier than I thought. Still, it's going to be a hard work implementing it, and I need your help.


There *IS* a wxTabCtrl. What we need to do is replicate (and possibly EXTEND like with tab context menus) the exact functionality of a wxNotebook by having the following structure:

<wxPanel>
  <wxBoxSizer with vertical orientation>
    <sizeritem: wxPanel>
    <wxBoxSizer with horizontal orientation>
      <sizeritem: wxTabCtrl />
      <sizeritem: wxBitmapButton />
    </wxBoxSizer>
    </sizeritem: wxPanel>
    <sizeritem: wxPanel>   
     <wxBoxSizer>
     <content goes here>
     </wxBoxSizer>
    </sizeritem:wxPanel>
  </wxBoxSizer>
</wxPanel>

If ANYONE can provide us with such a class, we'd be REALLY grateful.

Ceniza:

--- Quote from: wxWidgets' wiki ---wxTabCtrl is only supported under Win32, MacOS and OS/2.
--- End quote ---

And in fact, tabctrl.h hasn't include when using __WXGTK__:


--- Code: ---#if defined(__WXMSW__)
#include "wx/msw/tabctrl.h"
#elif defined(__WXMOTIF__)
#include "wx/motif/tabctrl.h"
#elif defined(__WXGTK__)
#elif defined(__WXMAC__)
#include "wx/mac/tabctrl.h"
#elif defined(__WXPM__)
#include "wx/os2/tabctrl.h"
#endif
--- End code ---

It seems like it won't help either.

rickg22:
Bummer. :( It was doing so well...

HMMMMMMMMMM wait a minute....

:D I know! We'll implement the modified notebook if we're on windows, and the standard notebook if we're on Linux! Well, that solves half of the problem at least... :roll:

takeshimiya:
Damn GTK and her native tab widgets :P
Well, from now C::B will use motif in linux :D (joke)

But seriously talking, I think that I saw some discussion about this in the wx mailing list, or it was a wx bounty (don't remember well)

AkiraDev:
How about having the main frame count the amount of open files, and if there is at least one, a small close button is drawn on top of the menu bar, to the right (emulating "classic" MDI) ?

Navigation

[0] Message Index

[#] Next page

Go to full version