-
Splash Window In VC++
currently the positions of my bitmaps and buttons on the opening window are set in the IDD_Splash section, by physically moving them into the locations on the window. I put 2 all the way on the right edge. however, depending on the computer screen resolution, sometimes the bitmaps are on the edge, sometimes away from the edge. is there another way to display bitmaps and buttons more accurately? maybe the way windows can be displayed using proportions of the parent window, not in absolute terms?
Last edited by jimlau; 05-26-2010 at 06:56 PM.
-
I do not know the best way to handle this. One easy way is to splash with directx (directdraw?). Get the resolution, scale to fit it, and display your image for a moment at a reasonable scale. However this could result in pages of code for so simple a task.
Are splash screens still "IN" ? I always hate waiting for such junk to go away so I can do whatever it was I wanted to do. I havent seen a program with a splash in a while, so maybe this style of applicaiton has gone away or is somewhat less in style?
-
not sure a splash screen is any different than other windows. anyway, this is the code i use to put the icons in the window. but i don't know of a function that includes coordinates, instead of width and height.
BOOL CSplashDlg::OnInitDialog()
{
CDialog::OnInitDialog();
HICON hIcon10 = (HICON) ::LoadImage(GetModuleHandle(NULL),MAKEINTRESOURCE(IDI_EXIT2),IMAGE_ICON,60,32,LR_DEFAULTSI ZE | LR_SHARED);
((CButton*)GetDlgItem(IDOK))->SetIcon(hIcon10);
CRect rect;
SystemParametersInfo(SPI_GETWORKAREA, 0, &rect, 0);
MoveWindow(&rect);
return TRUE;
}
-
http://msdn.microsoft.com/en-us/visualc/cc721654.aspx
Maybe this will help.
I was doing it using a third party library called wxwidgets from way back, I do not know if that is still a good, current package to use but it had a nice splash screen.
Similar Threads
-
By wrappingduke in forum Mobile
Replies: 4
Last Post: 05-15-2008, 04:17 PM
-
By Usha.R in forum ASP.NET
Replies: 1
Last Post: 02-14-2006, 04:30 AM
-
By Dennis in forum VB Classic
Replies: 10
Last Post: 02-15-2001, 04:52 AM
-
By TC in forum VB Classic
Replies: 8
Last Post: 09-26-2000, 02:34 AM
-
By TC in forum VB Classic
Replies: 0
Last Post: 09-25-2000, 09:06 AM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Development Centers
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center
|