Click here to Skip to main content
15,897,518 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Clipping child windows Pin
Jesper Knudsen8-Aug-05 20:40
Jesper Knudsen8-Aug-05 20:40 
GeneralRe: Clipping child windows Pin
John R. Shaw8-Aug-05 22:14
John R. Shaw8-Aug-05 22:14 
GeneralRe: Clipping child windows Pin
Jesper Knudsen8-Aug-05 22:28
Jesper Knudsen8-Aug-05 22:28 
GeneralRe: Clipping child windows Pin
John R. Shaw8-Aug-05 23:16
John R. Shaw8-Aug-05 23:16 
GeneralRe: Clipping child windows Pin
Jesper Knudsen8-Aug-05 23:37
Jesper Knudsen8-Aug-05 23:37 
GeneralRe: Clipping child windows Pin
John R. Shaw9-Aug-05 10:06
John R. Shaw9-Aug-05 10:06 
GeneralRe: Clipping child windows Pin
John R. Shaw9-Aug-05 13:47
John R. Shaw9-Aug-05 13:47 
GeneralRe: Clipping child windows Pin
Jesper Knudsen9-Aug-05 20:35
Jesper Knudsen9-Aug-05 20:35 
Yes, this is excactly what I'm doing. When the user clicks a cell, I create a new cedit and places it at the cell position. Trouble is vertical scrolling - the newly created cedit will draw on top of (instead of beneath) the header row drawn by the parent.

I took a look at Mauders grid control, but you'll notice that he scrolls in steps of 'row height', so he can hide the entire cedit instead of clipping it.

I'd like smooth scrolling (pixel by pixel), so it's possiblt for the cedit to be partly hidden beneath the header row.

Usually child wnd's are clipped to the parents client rect. Eg you can create a new cedit at location CRect(10,-10,100,10) and it will be partly hidden.

CRect cr;<br />
GetClientRect(&cr);


always as (0,0) as upper left corner, and 'size-of-cwnd' as the lower right corner. This client rect defines the clipping rect to which child cedits are clipped. And this is the rect I want to modity by eg:

cr.top += HEADER_ROW_HEIGHT;<br />
ClipChildrenToThisRect(&cr);


Kno' I mean?

Smile | :)

Simple is beautiful
GeneralRe: Clipping child windows Pin
John R. Shaw13-Aug-05 17:07
John R. Shaw13-Aug-05 17:07 
GeneralRe: Clipping child windows Pin
Jesper Knudsen17-Aug-05 1:31
Jesper Knudsen17-Aug-05 1:31 
GeneralWindows messages Pin
Ali Tavakol7-Aug-05 20:58
Ali Tavakol7-Aug-05 20:58 
GeneralRe: Windows messages Pin
khan++7-Aug-05 21:35
khan++7-Aug-05 21:35 
GeneralRe: Windows messages Pin
Ali Tavakol8-Aug-05 19:10
Ali Tavakol8-Aug-05 19:10 
GeneralRe: Windows messages Pin
John R. Shaw8-Aug-05 21:05
John R. Shaw8-Aug-05 21:05 
GeneralArabic text for Windows control classes Pin
Ali Tavakol7-Aug-05 20:41
Ali Tavakol7-Aug-05 20:41 
GeneralRe: Arabic text for Windows control classes Pin
ThatsAlok7-Aug-05 20:59
ThatsAlok7-Aug-05 20:59 
GeneralRe: Arabic text for Windows control classes Pin
John R. Shaw8-Aug-05 21:40
John R. Shaw8-Aug-05 21:40 
GeneralRe: Arabic text for Windows control classes Pin
Ali Tavakol10-Aug-05 23:09
Ali Tavakol10-Aug-05 23:09 
GeneralRe: Arabic text for Windows control classes Pin
John R. Shaw13-Aug-05 18:02
John R. Shaw13-Aug-05 18:02 
GeneralOpening a File/URL with default browser Pin
retro_coder7-Aug-05 20:31
retro_coder7-Aug-05 20:31 
GeneralRe: Opening a File/URL with default browser Pin
khan++7-Aug-05 20:51
khan++7-Aug-05 20:51 
GeneralRe: Opening a File/URL with default browser Pin
ThatsAlok7-Aug-05 20:54
ThatsAlok7-Aug-05 20:54 
GeneralRe: Opening a File/URL with default browser Pin
retro_coder7-Aug-05 21:10
retro_coder7-Aug-05 21:10 
GeneralRe: Opening a File/URL with default browser Pin
ThatsAlok7-Aug-05 20:53
ThatsAlok7-Aug-05 20:53 
Generalhelp me ..how to convert MFC application in activeX dll Pin
rajesh_kapure7-Aug-05 20:00
rajesh_kapure7-Aug-05 20:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.