I solved the subclassing problem. In case there is
anyone who didn't know, it seems the window that gets
scintilla notifications is a child window of class
"SciTEWindowContent". The code for finding it is: 

HWND hwndParent = ::FindWindow("SciTEWindow", NULL); 
hwndHost = FindWindowEx(hwndParent,   null, 
"SciTEWindowContent",  null);

and then you subclass the window as usual. 

HJS

--- Hans Joseph Solbrig <[EMAIL PROTECTED]> wrote:

> 
> --- Neil Hodgson <[EMAIL PROTECTED]> wrote:
> 
> > Hans Joseph Solbrig:
> > 
> > > I would like it to both filter the keys coming
> to
> > > application (not just the regular characters)
> and
> > > perform background processing.
> > 
> >    The standard technique for filtering keys is to
> > subclass the Window.
> >
> 
> Thanks for the pointer. I've been playing with
> subclassing Scite. I am guessing one would want to
> subclass the window class "SciTEWindow". I find a
> window of that class with findwindow and use
> SetClassLong to subclass it but when I do that,
> nothing calls my WndProc - scite works perfectly but
> I
> get no messages coming to the function. I would like
> to get a HWND value more directly but I can't figure
> out how from the extensionAPI. 
> 
> I got the idle processing working quite well using a
> subwindow but I want to put it all on one wndProc so
> that needs to work for any of it to work. 
> 
> Anyway, thanks muchly for the help so far, 
> 
> my code for doing the subclassing is:
> 
>   hwndHost = FindWindow("SciTEWindow", "");
>   assert(hwndHost);
>   theOldWndProc = reinterpret_cast<FARPROC> 
>     (::SetClassLong(
>       hwndHost, GCL_WNDPROC, 
>       reinterpret_cast<LONG_PTR>(MyNewWndProc)
>   ));
>   tickerID = ::SetTimer(hwndHost,// MainHWND(), 
>     patternIdleTimerID, 1, (TIMERPROC) NULL
>   );
>   ::SendMessage(hwndHost,
>     STE_WM_DO_BACKGROUND_PROCESSING,0, 0);
> 
> Again, thanks for the help,
> 
> Hans Joseph Solbrig
> 
> 
> 
>  
>
____________________________________________________________________________________
> Have a burning question?  
> Go to www.Answers.yahoo.com and get answers from
> real people who know.
> _______________________________________________
> Scintilla-interest mailing list
> [email protected]
>
http://mailman.lyra.org/mailman/listinfo/scintilla-interest
> 



 
____________________________________________________________________________________
Expecting? Get great news right away with email Auto-Check. 
Try the Yahoo! Mail Beta.
http://advision.webevents.yahoo.com/mailbeta/newmail_tools.html 
_______________________________________________
Scintilla-interest mailing list
[email protected]
http://mailman.lyra.org/mailman/listinfo/scintilla-interest

Reply via email to