Search found 396 matches

by sethjackson
Fri Apr 28, 2006 3:34 pm
Forum: C++ Development
Topic: wxNotebook Tab context menu
Replies: 9
Views: 1420

Re: wxNotebook Tab context menu

Hi will wxNotebook ever have context menu support? An easy way to do this would be using a mouse event for the notebook. Connect an event handler like m_notebook->Connect( wxID_ANY, wxEVT_RIGHT_UP ,wxMouseEventHandler(MyFrame::OnRightClick),NULL,this ); An create a wxMenu in the handler and call wx...
by sethjackson
Fri Apr 28, 2006 3:11 pm
Forum: C++ Development
Topic: wxNotebook Tab context menu
Replies: 9
Views: 1420

wxNotebook Tab context menu

Hi will wxNotebook ever have context menu support?

Something like this.

Code: Select all

EVT_NOTEBOOK_CONTEXT_MENU(...)
I think it is possible (Think Firefox. Maybe they owner-draw the tabs though)....
by sethjackson
Wed Apr 26, 2006 1:35 am
Forum: Open Discussion
Topic: License issue that can i statically link modefied wxWindow?
Replies: 7
Views: 1371

lowjoel wrote:We need to set up a sticky regarding licensing; I've seen quite a bit of licensing questions lately. opinions?
Sticky 1

No sticky 0

Yes that would be a good idea. :)
by sethjackson
Tue Apr 25, 2006 10:07 pm
Forum: General Development
Topic: Singleton template problem
Replies: 2
Views: 701

Aww..... Ok. Thanks. :D
by sethjackson
Tue Apr 25, 2006 5:47 pm
Forum: General Development
Topic: Singleton template problem
Replies: 2
Views: 701

Singleton template problem

Hi. I keep getting link errors with this code... I'm probably doing something dumb. :P Can someone help? Thanks. singleton.h #ifndef SINGLETON_H #define SINGLETON_H template<class T> class Singleton { public: static T* Get(); static void Free(); protected: Singleton(); ~Singleton(); private: static ...
by sethjackson
Sun Apr 23, 2006 5:01 pm
Forum: C++ Development
Topic: Build an Image from raw data.
Replies: 5
Views: 883

micros wrote:
farocam wrote:How do we order the data ? Should it be RGB ?
Yes, I think it's 1 byte R, then 1 byte G, then 1 byte B. If yellow turns out azure, then you'll have to swap R and B. But I think it won't, since only the windows BMP format is that "unnatural" BGR.
Umm TGA files are BGR....
by sethjackson
Sun Apr 23, 2006 12:50 pm
Forum: Compiler / Linking / IDE Related
Topic: Is there any #ifdef __MINGW__ ?
Replies: 5
Views: 1133

kornerr wrote:Thanks, sethjackson!
Your welcome. :D
by sethjackson
Sun Apr 23, 2006 12:42 pm
Forum: Compiler / Linking / IDE Related
Topic: Is there any #ifdef __MINGW__ ?
Replies: 5
Views: 1133

Re: Is there any #ifdef __MINGW__ ?

My app uses mkdir function which has a bit different declaration in Linux ( mkdir (const char*, unsigned int) ) and in MinGW ( mkdir (const char*) ). I tried this: #ifdef __GNUG__ mkdir (dir.c_str (), 1); #else mkdir (dir.c_str ()); #endif but GCC is used under MinGW either :) Is there a way out of...
by sethjackson
Sun Apr 23, 2006 12:38 pm
Forum: C++ Development
Topic: Issues with font sizes/resizing forms
Replies: 4
Views: 555

http://wxwidgets.org/manuals/2.6.3/wx_wxfont.html#wxfont I would set the font size when you start up your app. Something like this. MainFrame::MainFrame(wxWindow *parent, int id, wxString title, wxPoint pos, wxSize size, int style) : wxFrame(parent, id, title, pos, size, style ) { wxFont font(8, wxM...
by sethjackson
Sun Apr 23, 2006 12:27 pm
Forum: C++ Development
Topic: Transparent rectangle drawing
Replies: 3
Views: 1660

Miles Lombardi wrote:Lol, way too an extensive an answer, lol. I knew how to draw rectangles :).

But thanks :D.
LOL glad you got it working. :D
by sethjackson
Sat Apr 22, 2006 2:34 pm
Forum: C++ Development
Topic: Transparent rectangle drawing
Replies: 3
Views: 1660

I don't think there is a wxTransparentBrush.... From http://www.wxwidgets.org/manuals/2.6.3/wx_wxdc.html#wxdcdrawrectangle wxDC::DrawRectangle void DrawRectangle(wxCoord x, wxCoord y, wxCoord width, wxCoord height) Draws a rectangle with the given top left corner, and with the given size. The curren...
by sethjackson
Sat Apr 22, 2006 1:26 pm
Forum: C++ Development
Topic: Memory Leak in wxWidgets?
Replies: 32
Views: 5101

I never thought about multiple viewports (I haven't used them). :P
I hope you don't mind if I post your code in the bug rpt......
by sethjackson
Sat Apr 22, 2006 1:08 am
Forum: General Development
Topic: std::cerr
Replies: 3
Views: 990

Thanks both of you. That answers my std::cerr question.

I decided to do it like this though.

Code: Select all

Exception::Exception(const std::string& message, const std::string& file, const int line)
{
    std::ofstream log("errorlog", std::ios_base::app);

    log << ...;
}
by sethjackson
Fri Apr 21, 2006 7:09 pm
Forum: General Development
Topic: std::cerr
Replies: 3
Views: 990

std::cerr

How do I use this? I have some code. #ifndef EXCEPTION_H #define EXCEPTION_H #include <string> class Exception { public: Exception(const std::string& message, const std::string& file, const int line); ~Exception(); }; #endif // EXCEPTION_H #include <iostream> #include "exception.h" Exception::Except...