   Creating a large window
  I'm trying to create a window where I am manipulating a scanned bitmap, the size of the bitmap I want it 2551x3000, when I try to create a window using:   hWnd = CreateWindow(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW , 0, 0, 2551, 3000, NULL, NULL, hInstance, NULL);It only seems to create the window the width of my monitor 1920, the right most 500  or so is cut off... any ideas??oh, working in vc++2008, not a game or anything I'm trying to read on/off pixels from a scanned image (i.e. how many pixels are black on a sheet of paper)...Thanks,rhuala   
  You'll probably want to look into scrollbars.hWnd = CreateWindow(szWindowClass, szTitle, WS_OVERLAPPEDWINDOW | WS_VSCROLL |WS_HSCROLL , 0, 0, 1280, 1024, NULL, NULL, hInstance, NULL);Then you'll want to process the various scroll bar messages so that you change the starting x,y point of the image you want to show in your window at it's 0,0 location.Alternatively you could stretchblt the image into whatever sized window you have.However, if the image is just in memory and you're just counting black pixels, you should be able to just wor with the image in memory at whatever size it is.   ;  seriously? I can't make the window bigger then my display setting?? No way to over ride this...Yeah I could use scroll bars but its a hassle to implement, I'd much rather just make the window bigger and drag it over to see things and look for mistakes...I guess I could do a stretchblit but then I can't see things with as much detail, if I really can't make a bigger window that's the way I'll go I guess, but I'd really just like to have a big window... :(And you are right I could just count pixels from memory, the problem is I have to show people how it works and what it's doing...Regards,rhuala   ;  I don't get it.If you have a bigger window than the display, that won't help you at all. You cannot drag the window (titlebar) off the screen, so you will never be able to SEE the bottom of the picture.How about making an app, that drags the image on left mouse button down? Or middle/right. It's very easy to add this "feature".EDIT: typo[Edited by - szecs on May 11, 2010 10:56:24 AM];Quote:Original post by rhualaseriously? I can't make the window bigger then my display setting?? No way to over ride this...Yeah I could use scroll bars but its a hassle to implement, I'd much rather just make the window bigger and drag it over to see things and look for mistakes...I guess I could do a stretchblit but then I can't see things with as much detail, if I really can't make a bigger window that's the way I'll go I guess, but I'd really just like to have a big window... :(And you are right I could just count pixels from memory, the problem is I have to show people how it works and what it's doing...Regards,rhualawhy would scrollbars not work? You still get all the detail. The only bad thing for you is you can't see it all at the same time, which you wouldn't get anyway with what you're describing.I'm pretty sure the reason a window can't be bigger than your monitor is because it doesn't make any sense. It would make an application significantly difficult and dangerous to use for the lay user. The top right corner of all windows (in a windows environment) has the important functions on it (minimize, close). If you got the top bar off the screen(not possible. I'm sure for this reason.) and each of the side bars off the screen you would be stuck with a window that's too large to move or close, which is silly.;  okay I'll give it a try... anyone have a quick tutorial on how to correlate the scroll bars to a function, basically will just be changing the x,y location of BitBlt(hdc, 0, 0, PicWidth , PicHeight, hdcPaint, x, y,  SRCCOPY);and map this to the x of the h-bar, and y to the v-bar position...Thanks,rhuala   ;  read posts more carefully.If you want a quick solution, forget about the scrollbars.Pan the image with the left/middle/or right mouse button drag.It's very easy to do.   ;  Hi, yes I did read your post, I just didn't like it... yes moving it around with a mouse click hold down is easy but not very intuitive for a new user, I prefer the scroll bar method...So anyways, if anyone can suggest a good link to learn about how to use the scroll bars would be appreciated... looked through Google I found this but the author looks like he's on crack cocaine...http://www.codeproject.com/KB/miscctrl/scrollbar.aspxrhuala   ;  In Win32 there two kinds of scroll bars, standalone scroll bar controls and scroll bars that are part of an overlapped window. The first kind you create with CreateWindowEx like any other control and the other kind you get by specifying  window styles when creating the overlapped window. The interface in both cases is about the same. Here's the documentation for standalone scroll bar controls.;  Thanks   