Project Home
Project Home
Trackers
Trackers
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Moving Window from PhWindowOpen to Front/Back: (3 Items)
   
Moving Window from PhWindowOpen to Front/Back  
I'm creating a window with PhWindowOpen. I need to be able to move it to the front and to the back. I found that it can 
be done for Pt based object with PtWindowToFront and PtWindowToBack. How can this be done without using the Pt calls?

Thx.
Bill
Re: Moving Window from PhWindowOpen to Front/Back  
You can use this function -- PtForwardWindowEvent():

to_back( PhRid_t rid ) {
 PhWindowEvent_t WE = { 0 };
 WE.event_f = Ph_WM_TOBACK;
 WE.rid     = rid;
 PtForwardWindowEvent( &WE );
}

to_front( PhRid_t rid ) {
 PhWindowEvent_t WE = { 0 };

 WE.event_f = Ph_WM_TOFRONT;
 WE.rid     = rid;
 PtForwardWindowEvent( &WE );

 WE.event_f = Ph_WM_FOCUS;
 WE.rid     = rid;
 PtForwardWindowEvent( &WE );
}

-Misha.
Re: Moving Window from PhWindowOpen to Front/Back  
Thx. That did the trick.