Old 13th November 2011, 03:59   #1
anandharaja
Member
 
Join Date: Mar 2009
Posts: 50
Question How to add background images in UltraModern UI ?

hi,
i like to create installer with changing background images, like what we seen while installing the games, Using UltramodernUI without side image and i don't like that much size of window while installing files, during the installation window show contain one progress bar with file installation details.

i refereed UMUI help file, able to use Custom bg but i want to position the image as default size 800 x 600 in screen center and the background color should be black, how can i do that.

i hope explained everything clearly.
anandharaja is offline   Reply With Quote
Old 20th November 2011, 03:53   #2
anandharaja
Member
 
Join Date: Mar 2009
Posts: 50
No reply means no one understand my question?

Ok this is the script i using
code:
;Background Image
!macro UMUI_BG
SetOutPath "$PLUGINSDIR"
File "C:\Users\AnandhaRaja\Desktop\MY Program\BackGround.bmp"
BgImage::SetBg /NOUNLOAD /GRADIENT 00 000 000 00 000 000
BgImage::AddImage /NOUNLOAD "$PLUGINSDIR\BackGround.bmp" 200 150
CreateFont $1 "Verdana" 30 700
BgImage::AddText /NOUNLOAD "$(^Name)" $1 255 255 255 10 65 -1 -1
BgImage::Redraw /NOUNLOAD
!macroend

!macro UMUI_BG_Destroy
BgImage:: Destroy
!macroend


;_--------------------------------------

everything is ok but i want to position the 1024 X 768 image in center of the screen in all resolution. and during the installation the window should be small and want to position in bottom of the screen.
hope now you understand my problem.
anandharaja is offline   Reply With Quote
Old 21st November 2011, 06:03   #3
T.Slappy
Major Dude
 
T.Slappy's Avatar
 
Join Date: Jan 2006
Location: Slovakia
Posts: 521
Send a message via ICQ to T.Slappy
I do not see any problem: if these lines
PHP Code:
BgImage::SetBg /NOUNLOAD /GRADIENT 00 000 000 00 000 000
BgImage
::AddImage /NOUNLOAD "$PLUGINSDIR\BackGround.bmp" 200 150 
are working for you fine then why for 1024*768 px picture they should not?

If you need a little clue for all steps, here you are:
Simply calculate each image position (X, Y) based on image dimensions and screen resolution.
Create simple timer (running in separated thread) which will pick one image (by random or as sequence 1-2-3-...) and simply show it using BgImage plug-in.
Move main window to the right-lower corner (I would use this simple function: http://msdn.microsoft.com/en-us/libr...=vs.85%29.aspx)
If you want to change dimensions of NSIS window then simply modify UI .exe file using ResHacker (or do it programatically) - there may be a little problem if you want to have exactly the same kind of progress bar window like InstallShield - based on your decision.

And that is all. As easy as pie.
We cannot wrote whole code/installer for you!

Cool looking skinned Graphical Installers: www.graphical-installer.com
I offer NSIS scripting, C/C++/C#/Delphi programming: www.unsignedsw.com
Develop NSIS projects in Visual Studio 2005-2017: www.visual-installer.com
or RAD Studio 2009, 2010, XE-10.2 Tokyo: www.rad-installer.com
T.Slappy is offline   Reply With Quote
Old 21st November 2011, 16:48   #4
anandharaja
Member
 
Join Date: Mar 2009
Posts: 50
Thanks T.Slappy for your reply

Yes, i want create window like installshield during installation. my screen resolution is 1920 X 1080 but the background image is 1024 x 768 size, so want to position the image in center of the screen what ever may be the resolution, is possible?

ThankYou
anandharaja is offline   Reply With Quote
Old 22nd November 2011, 13:54   #5
anandharaja
Member
 
Join Date: Mar 2009
Posts: 50
hi,
i want the change installation window size of UMUI using resource hacker, which dialog i want to modify and the rest of the windows size is same.
anandharaja is offline   Reply With Quote
Old 23rd November 2011, 08:39   #6
T.Slappy
Major Dude
 
T.Slappy's Avatar
 
Join Date: Jan 2006
Location: Slovakia
Posts: 521
Send a message via ICQ to T.Slappy
This is the tricky part:
you can change UI file for whole installer but not for separated page.
So I suggest to use default UI and when installation begins [executing Sections] then hide whole installer and show window with progress bar - which will be created with simple plug-in.

Cool looking skinned Graphical Installers: www.graphical-installer.com
I offer NSIS scripting, C/C++/C#/Delphi programming: www.unsignedsw.com
Develop NSIS projects in Visual Studio 2005-2017: www.visual-installer.com
or RAD Studio 2009, 2010, XE-10.2 Tokyo: www.rad-installer.com
T.Slappy is offline   Reply With Quote
Reply
Go Back   Winamp & SHOUTcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump