[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[fxscintilla-users] RE: example seems to not work
From: |
David Hisel |
Subject: |
[fxscintilla-users] RE: example seems to not work |
Date: |
Mon, 20 Oct 2003 17:11:20 -0400 |
I'm using cygwin and using FOX-1.1.38. My program compiles just fine, and
it even runs, but no window shows up, any suggestions?
Here's the code:
// ------------------------------------------------------------------------
// sc.cpp
//
// Time-stamp: <2003/10/14 16:15:22, address@hidden> (s/trash@/david@/)
// cygwin> uname -ro
// 1.5.5(0.94/3/2) Cygwin
// FOX-1.1.38
// (./configure --disable-shared --prefix=/usr; make; make install;
// ln -s /usr/lib/libFOX-1.1.a /usr/lib/libfox.a;
// ln -s /usr/lib/libFOX-1.1.la /usr/lib/libfox.la)
#include <fox/fx.h>
// FXScintilla-1.53 (./configure --prefix=/usr;make;make install)
#include <fxscintilla/Scintilla.h>
#include <fxscintilla/FXScintilla.h>
using namespace FX;
// compile this example with:
// g++ -o sc.exe -O2 -mwindows -e _mainCRTStartup sc.cpp -lfxscintilla -lfox
-lcomctl32
int main(int argc, char ** argv)
{
FXApp application("FXScintilla");
application.init(argc, argv);
FXMainWindow *win =
new FXMainWindow(&application, "FXScintilla Example");
// Instantiate an FXScintilla widget
FXScintilla *scint =
new FXScintilla(win, NULL, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y);
// The Scintilla programming interface is through messages
// à la Windows (see scintilla/doc/ScintillaDoc.html)
scint->sendMessage(SCI_STYLESETFONT, STYLE_DEFAULT, (long)"Courier New");
scint->sendMessage(SCI_STYLESETSIZE, STYLE_DEFAULT, (long)10);
scint->sendMessage(SCI_STYLECLEARALL, 0, 0);
application.create();
win->show(PLACEMENT_DEFAULT);
return application.run();
}
// ------------------------------------------------------------------------
when I run sc.exe, focus is taken from my rxvt, but no window shows up.
Am I compiling this correctly? (see comments for compile cmd line)
Are any code statements out of order?
Any suggestions?
Thanks,
David Hisel
http://www.hisel.com/
- [fxscintilla-users] RE: example seems to not work,
David Hisel <=