wxTabCtrl is only supported under Win32, MacOS and OS/2.
#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
As far as the toolbar is concerned, add the following buttons after Save:
1] Save All
2] Close (current tab/file)
3] Close All
Did anyone notice that Mozilla also has a "New Tab" button on the left side as well as a "Close Tab" on the right.
The notebook code calls "wx/generic/tabg.h", so what I believe needs to be changed is "tabg.h" and "tabg.cpp" in wx to have a controlled left and right margin something like it has for the top margin. I think these files are generic to all wx versions. The left/right margin should act something like (and in addition to) the m_tabHorizontalOffset value. These margins would allow the addition of the button(s) to the left and right sides of the notebook in the tabs area.
I have an idea that might work:
...Somehow, you'd have to make wxNotebook only as high as the tabs.
* Much thanks to the aMule project for the GPL code
* for their CLOSABLENB, which is used here for
* the code for the popups, and the events are based on
* them.
After a few minor changes I got it to compile under Windows and works fine, then I tried to compile it under Linux and the only problems left were just the Unicode ones, and after fixing them... it works!
Now, the questions:
Will it be accepted and added to Code::Blocks?
Will the author mind if we take the code and use it at our will?
Is the current implementation enough or will it need more things to be implemented?
I think the first two are the most important ones. The way it looks must be taken into account too.
So... answers?
If you dont like the VC71 style - you can use the standard style, or wait until I will finish the gradient colored tabs (wont take long now)
mandrav: the test program is already included with wxFlatNotebook, but I'll attach his current version with Code::Blocks project files. Haven't tested with UNICODE build yet.
What happen if you change the size of the application? (resizing it - does it help?)
mandrav: could you update to the latest version and try again? The project files I provided work for that one too.
I agree, from the next version I will place in the header file the version number.
Happy to hear that it was your bug :wink:
I am currently of working on the some annoying bug with the middle button close - it selects the file, and then closes it.
After it I will start working on wxFNB_BOTTOM style - place the tabs on the bottom part of the book.
I already added an options to remove the 'x', '<>' buttons - so you can now use the control for the other windows as well
and not only as the main editor container for scintilla editors (you are using scintilla, right?)
Eran
// the event handler allows it?
if (!event.IsAllowed())
return;
mandrav: Can you please send me the source files? instead of what you sent? (i guess it is an output of the SVN you are using, I am not familiar with it).
I am using araxis to merge the files - so just send out your files, and i will do the rest.
+++ wxFlatNotebook\include\wx\wxFlatNotebook\wxFlatNotebook.h Tue Jan 03 23:45:17 2006
@@ -104,7 +104,7 @@
/**
\param page - index of page to be deleted
*/
- void DeletePage(size_t page);
+ void DeletePage(size_t page, bool notify = true);
/// Deletes all notebook pages and destroys all windows associated with pages
bool DeleteAllPages();
I am familiar with soruce controls, In fact, I am running 2 CVS servers at home ... (I have other projects as well).
And I am using TortoiseCVS as my client.
I also submitted a request to soruceforge to host my sources, in case it will accept, I will get CVS access and storage for the sources so other developers will have access instead of sending me files to do the merge.
Eran
I am familiar with soruce controls, In fact, I am running 2 CVS servers at home ... (I have other projects as well).Ah sorry :)
And I am using TortoiseCVS as my client.
Just a quick question:
Which of the three styles that I provided are you going to choose for C::B?
Or is it going to be configurable?
Btw, I also wrote an IDE (I stopped developing it however) - I will be happy to share some of my features with you guys.
Eran
Btw, I also wrote an IDE (I stopped developing it however) - I will be happy to share some of my features with you guys.
Which of the three styles that I provided are you going to choose for C::B?
Or is it going to be configurable?
Btw, I also wrote an IDE (I stopped developing it however) - I will be happy to share some of my features with you guys.
It already is configurable ;)
(I will commit in a while)
Sharing is always good :lol:
Just remember to report all those bug fixes to eranif :)
I'll be waiting a while for you to commit it, really, I'll be patient :)
Oh, forgot to ask in the last post: will you change the Management and Messages tabs too? If the answer is NO, why not?
Just remember to report all those bug fixes to eranif :)
Oh, forgot to ask in the last post: will you change the Management and Messages tabs too? If the answer is NO, why not?
return m_pages->GetClientSize();
I will apply the patch you sent me ASAP...
Good news: the current version compiles under Linux (after the few minor fixes, namely an address operator missingAlready fixed: an '&' was missing before the address of the callback function in the drag'n'drop constructor and will be published on the next release
Bad news: adding a new page makes it crash (the crash point is a bit unclear, maybe a wxGTK problem).
wxTextCtrl *text = new wxTextCtrl(book, wxID_ANY, caption, wxDefaultPosition, book->GetPageBestSize(),
wxTE_MULTILINE);
wxTextCtrl *text = new wxTextCtrl(book, wxID_ANY, caption, wxDefaultPosition, wxDefaultSize,
wxTE_MULTILINE);
From the diff i mainly see that you added an overloading function with notify flag set to true for DeletePage(page, notify), and RemovePage(), however, this is not needed anymore since I already fixed the code couple a days ago that when closing a page, and event will be sent AND will be handled properly (including veto by the event handler).
You also added an event firing when pressing on mouse middle click - also not needed, since the DeletePage() function is always sending an event
Correct me if I am wrong here.
revision 1654 : does not build :
Compiling: src\resources\resources.rc
src\resources\resources.rc:9:24: wx/msw/wx.rc: No such file or directory
Add double quotes to that path.
[edit]
tiwag: I was just going to ask you if you also got Disassembly as the title for the Opened files list, but I already see it in your screenshot :P
[/edit]
tiwag: I was just going to ask you if you also got Disassembly as the title for the Opened files list, but I already see it in your screenshot :P
Compiling: src\resources\resources.rc
src\resources\resources.rc:9:24: wx/msw/wx.rc: No such file or directory
Compiling: src\startherepage.cpp
Linking executable: devel\codeblocks.exe
Ok, I got it to show correctly, but now my old Layout isn't deleted (if I restart Code::Blocks it's there again).
BUT still problem :
Compiling: src\resources\resources.rc
src\resources\resources.rc:9:24: wx/msw/wx.rc: No such file or directory
and look at this, build does not even stop !!
BUT still problem :
Compiling: src\resources\resources.rc
src\resources\resources.rc:9:24: wx/msw/wx.rc: No such file or directory
Try adding $(#WX.INCLUDE) in src target resource dirs.
BUT still problem :
Compiling: src\resources\resources.rc
src\resources\resources.rc:9:24: wx/msw/wx.rc: No such file or directory
Try adding $(#WX.INCLUDE) in src target resource dirs.
I saw this is already specified on the global level of the cbp file, nevertheless trying it out
[EDIT] : no luck :( :(
Why why why ?? Heeeeeeeeeeeeeeeeeeelp
this was on my laptop, on my pc it builds (so a nightly build will come up)
BUT still problem :
Compiling: src\resources\resources.rc
src\resources\resources.rc:9:24: wx/msw/wx.rc: No such file or directory
Try adding $(#WX.INCLUDE) in src target resource dirs.
I saw this is already specified on the global level of the cbp file, nevertheless trying it out
[EDIT] : no luck :( :(
Why why why ?? Heeeeeeeeeeeeeeeeeeelp
this was on my laptop, on my pc it builds (so a nightly build will come up)
This ansi or unicode? Should be mswu for unicode...
This ansi or unicode? Should be mswu for unicode...not for the resource, it's to be seen as a regular source file
tiwag: I was just going to ask you if you also got Disassembly as the title for the Opened files list, but I already see it in your screenshot :P
This has to do with the layout having been saved with a previous version which didn't have the "open files list" as a docking window.
Just use the new "View->Layouts->Delete current" ;) (which I forgot to mention in the log message).
I can confirm that. default.conf is a one line mess now.anyhow - it's more save to use a xml editor.
would be nice if this becomes back multilined, text editors are nice also (if want to copy stuff from it) ;-)
There's something evil with the behaviour when you open a file when there's one opened already: the new tab will be added last but showed first, hiding all others.
CVS and bugfixes... nice :)
Did you apply mandrav's patches too?
« Reply #132 on: Today at 04:00:00 PM »
... converting MessageManager ...
Only the Management ones left, right?
When I commit the changes, you can take a look at the patch. I believe three fixes there will interest you
- However, I already fixed the SetSelection() function, unless you find some other new bug in it.
I dont have access to your SVN, so how will I be able to see the changes?
I assumed that when adding a window to the book, the parent of the new added window is the book itself
Btw, Did you get any progress with the Linux building and displaying?
Who is Yiannis?
Mandrav, Ok, I need to have your sourceforge user name
Forgot to ask something in the last post :(
mandrav: have you enabled the option to choose if the notebook will be shown at the top or the bottom?
Nevermind that ... already got it - mandrav is the user name in SF
You are now member in the wxflatnotebook project
but the Messages notebook is hardcoded to be top and the editor one to always be fancy :(
Top/bottom is set by right-clicking on a tab.
All three notebooks use the same style setting. Try going to "Settings->Environment" and pressing OK to force writing the settings again.
Did that and the editor's one is still fancy.
[edit]
I just opened it and it's still the same one line mess.
[/edit]
The evil bug attacks again!
Try this: in the messages dock select "Build log", close Code::Blocks and open it again. Now "Build log" will be the first tab and 3 (Code::Blocks, Code::Blocks Debug and Search Results) will be "hidden".
Fixed, thanks.
I noticed something in the Jan 12 build... sometimes the active editor's tab isn't shown.. i have to press the left and right arrows to see it.
Guys eranif just updated wxFlatNotebook...... Just a heads up
http://wxforum.shadonet.com/viewtopic.php?t=5761&start=90
Maybe this will fix our drop target problems.
Did you try to disable the drag'n'drop of the wxFlatNotebook using the style: wxFNB_NODRAG style?
Eran
Did you try to disable the drag'n'drop of the wxFlatNotebook using the style: wxFNB_NODRAG style?