Archive: show details, hide details


show details, hide details
If a customer click on the "show details" button there is no other button to "hide details"....

Should I change the source code to have this possiblity or is it planned for the future?

Thanks


What would you gain from hiding the details again? To me it doesn't really matter if they're shown or not.


yes to me it does not matter neither. But believe it or not that was the first feedback from a customer!. He thinks that if he can show the details he should be able to hide them as well.


I'sd say that customer is a little anal. But if that's what the customer wants... I think you would have to edit the source or make a plugin. But whatever you do, it's going to be hard if you don't know what your doing. Do you know any programming?


A customer is a king;).

Yes I am a programmer but I was hoping that this feature becomes a regular feature of NSIS. Because logically if you can do something you should be able to undo it.


Actually, with some of the installers I've come across, I wish I had that functionality. It really slows down the installation when you have an installer installing thousands of itty bitty files on a slow computer with the details showing... :(

My ±US$0.02...


It is designed in a way that it won't really slow down the installation.

I think it won't become an NSIS feature because it doesn't really make sense to have such a button and because it also gives problems with user interface design.

So if you really need this feature, you'll have to write it yourself. However, if you know a little about C programming, it should not be difficult.


I agree with mdlazreg.

I also recently created an installer using NSIS (my first with NSIS) and in fact one of the very first feedbacks from the customer was for such a requirement. (Hide Details option)

I think people intuitively look for the Hide Details option when they are allowed to "Show Details".

Though I do agree that just "Showing the Details" would NOT necessarily slow down the performance or anything.
Its just that USERS look for the HIDE option.

It would be great if this can become a regular feature in NSIS.


I was bored this morning (plus I'm ill) so I made a plugin which adds this feature. Works for both Modern UI and default NSIS.

http://nsis.sourceforge.net/wiki/Fil...Files-v0.2.zip

Enjoy!

Edit: v0.2 uploaded. ToggleInstFiles::Free removed (no longer necessary).

-Stu


Uploaded new version with some new features.
You can now set the button texts and choose to place the button on the right side.

http://nsis.sourceforge.net/wiki/Fil...Files-v0.3.zip

-Stu


:up:

Works great. You are da man!


I tried to download this plugin and it is corrupted. Where can I get a good copy of it?
Thank you.


Got it ... thanks :)


Hi Afrow,
I downloaded the stuff and put into my script but the final output comes out a bit sleazy. The upper border of the status bar becomes invisible and the upper part of the Show Details button is hidden by the captions which come up (those showing which command is currently running). Could you please suggest a solution for this soon...
Thanks,
Saaji


Could you attach a screenshot?

-Stu


yes, didn't think that you would reply this soon... thank you so much.:)

Spike1.bmp is the onne which comes up before I click on the Show Details button. After I move my mouse over it, that alone becomes visible.

Spike2.bmp is the final result after completion of installation. There too the upper part of the status bar is invisible.

And by the way can u suggest a way in which I can show "nice" comments in place of the commands which shows where the installer is currently. That way the user doesn't have to know what all are taking place within.
;)
Thanks,
Saaji


Use SetDetailsPrint and DetailPrint.


I see the problem. It's probably because of the font that you're using. What happens when you do not use the plugin? Does the text labels at the top still cover up the progress bar and / or button?

-Stu


I have uploaded another version http://nsis.sourceforge.net/wiki/Fil...eInstFiles.zip
The button and progress bar no longer have a fixed top. They'll now use the top value from the original progress bar.

-Stu


Cool Afrow, it works..
Thanks a lot man...
:)


I have strange thing with this plugins.
I work with nsis 2.08.
I made a "modern" setup and don't activate the plugins in
a specific section, I can click on the finish button.
If activate it, When I click on the Finish button, nothing are do and the the finish window aren't closed.


Could you make a cut down script which reproduces this problem?

-Stu


of course, I simplify my nsi project file and I attached it.


A good example,
I use our example "ExampleMUI.nsi"

...
Section "A section"

# Load plugin
ToggleInstFiles::Set /NOUNLOAD /RIGHT /SHOWTEXT "Show me!" /HIDETEXT "Hide me!"
SetAutoClose False
...

I comment this line like in my project.
SetAutoClose False

the installation go automaticaly on the nex page (the finish page) and the button finish do nothing...


Ahh ok I see. I'll look into that tomorrow.

-Stu


Thanks, fixed.
http://nsis.sourceforge.net/wiki/Fil...eInstFiles.zip

-Stu


heuuu,
The 0.5 version, continue to correspond to the 0.4 version of the DLL (14 JUL) .... :)


Are you sure?
I wasn't able to reproduce the problem with the 0.5 DLL
Have you made sure that the new DLL has replaced the old one?

-Stu


Sorry,
It's not what I want to say.
I just Download your new archive, and I check the version of
the DLL present of this archive, And the creation date of
this DLL is 14 JUL, and not today. Maybe it's upload prbs ?


Could be. I'll check now.

Edit:
Here's a direct link:
http://nsis.sourceforge.net/mediawik...eInstFiles.zip
Definately the latest version in there (last mod: 18 August 2005 @ 10:09)

-Stu


ok, you're right. It's my fault, or my firefox exactly, or the proxy of my company :), I get it with a direct connection with wget. and it's the 0.5 version. And it's work fine for me thanks a lot.


It's maybe a bug but I can't put it in Each section of my installation program.
If i do that, the installer crash at the seconc call,
If I want the installation doesn't crash, I need to put it in a specific section.
it is normal ?


Yes, you should only call it once in a dummy section:

Section
...
SectionEnd

Put it before any other Sections so it is executed first.
As long as the Section has no name, the user cannot uncheck it on the components page (it does not appear on there).

-Stu


Hi,

I watch something strange with this plugins, may be isn't
the plugins fault, but, I launch the setup example (generated with ExampleMUI.nsi). And after the installation,
the temporary directory created by nsis where the plugins are uncompressed. After the installation 'ToggleInstFiles.dll' aren't removed.
The temp folder in my case is:
'C:\Documents and Settings\MyNaaem\Local Settings\Temp\nsf20.tmp'
But the others plugins are removed....


I know why this is happening. It is because the plugin has to be called with /NOUNLOAD. This is preventing the DLL from being deleted because it is locked (in use).

I may have to add a dummy function in to unload the plugin (which would have to be called without the /NOUNLOAD flag) but I've asked KiCHiK if there is a better way to do this.

-Stu


A day late, but it's working.
Call ToggleInstFiles::Unload from the finish pages' PRE function (or of the next page after your install files page).
If you're using classic UI with no page's after your install files page, call ToggleInstFiles::Unload in both .onInstSuccess and .onInstFailed functions.

http://nsis.sourceforge.net/wiki/Fil...eInstFiles.zip

-Stu


Thanks for fixing this, Afrow. It is unloading now. :up:


I have sometinh strange with the 0.6 version.
I added that at the begining of my project:
juste before my last page.

!insertmacro MUI_PAGE_INSTFILES
; Remove the plugins
!define MUI_PAGE_CUSTOMFUNCTION_PRE UnloadToggleInstFiles
; Finish page
!insertmacro MUI_PAGE_FINISH

I have an hiddent section:

Section
ToggleInstFiles::Set /NOUNLOAD
SectionEnd

and I add the function at the bottom of my file:
## Unload plugin
Function UnloadToggleInstFiles
ToggleInstFiles::Unload
FunctionEnd

When I launch the setup, when I click in the finish button,
nsis crach. :(

I try to make an setup (witout anything to found why the crash appear). Your example MUI doesn't crash.


Added the following text to the readme:

"If you are not using AutoCloseWindow True or
MUI_FINISHPAGE_NOAUTOCLOSE, then you should call this from
.onInstSuccess and .onInstFailed also (otherwise a crash
will occur)."

"this" refers to ToggleInstFiles::Unload.

-Stu


OK, that crash on my case.

to explain, I use your example exampleMUI
I can't have MUI_FINISHPAGE_NOAUTOCLOSE set.
so I use the same method as example.nsi
I commment in example MUI the MUI_FINISHPAGE_NOAUTOCLOSE
and the call to the unload page, in the bottom of the
the script I comment too the function and I hadd the two functions:
.onInstSuccess
.onInstFailed

I generate it, And the script crash after the finish page.
you can found the complete script below:





!include MUI.nsh

## General settings
Name "ToggleInstFiles MUI Test"
OutFile "ToggleInstFilesMUI.exe"

## Page settings
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_INSTFILES
;!define MUI_PAGE_CUSTOMFUNCTION_PRE UnloadToggleInstFiles
;!define MUI_FINISHPAGE_NOAUTOCLOSE
!insertmacro MUI_PAGE_FINISH

!insertmacro MUI_LANGUAGE English

## Main section
Section "A section"

# Load plugin
ToggleInstFiles::Set /NOUNLOAD /RIGHT /SHOWTEXT "Show me!" /HIDETEXT "Hide me!"

# A general task
DetailPrint "Doing something..."
Sleep 5000

SectionEnd

## Unload plugin
Function .onInstSuccess
ToggleInstFiles::Unload
FunctionEnd

Function .onInstFailed
ToggleInstFiles::Unload
FunctionEnd

## Unload plugin
;Function UnloadToggleInstFiles
; ToggleInstFiles::Unload
;FunctionEnd


Archive: show details, hide details


Hmm thanks. I wasn't able to fix this problem unfortunately, which only occurs if MUI_FINISHPAGE_NOAUTOCLOSE or AutoCloseWindow true is set.

If you must use these two settings you won't be able to use ToggleInstFiles::Unload and you'll have to remove the $PLUGINSDIR manually after a reboot with:

RMDir /r /rebootok $PLUGINSDIR

Updated readme.

-Stu


OK
Maybe it's not completly what I want.
I want the panel where the the plugin is displayed (the copy of the files) changed when it 's finish to my finish panel, I don't want the user of my setup clic next AND click on the finish button. May I use the method ?


Sorry, I made a typo:

If you can't use these two settings you won't be able to use ToggleInstFiles::Unload and you'll have to remove the $PLUGINSDIR manually after a reboot with:

RMDir /r /rebootok $PLUGINSDIR

-Stu