最新消息:

NSIS皮肤插件

nsis 永恒心锁 1705浏览 0评论

对于一般的安装不推荐使用皮肤,因为此插件的最大缺点是容量大了,单单个DLL就4.02MB,而且还要附加.skf作为插件调用的皮肤!假如安装包大小过500MB或以上的使用也不错,至少能漂亮一些!

压缩包内有几个皮肤以及插件与说明,还有示例脚本,一看则明!

;NSIS_SkinCrafter_Plugin   
;Basic Example Script   
  
Function .onInit   
    ;User defined skin   
    SetOutPath $TEMP   
    File /oname=Deka_ST.skf "Deka_ST.skf"  
    NSIS_SkinCrafter_Plugin::skin /NOUNLOAD $TEMPDeka_ST.skf   
    Delete $TEMPDeka_ST.skf   
  
    ;Default Skin   
    ;NSIS_SkinCrafter_Plugin::skin /NOUNLOAD   
FunctionEnd   
  
Function .onGUIEnd   
 NSIS_SkinCrafter_Plugin::destroy   
FunctionEnd   
  
Function un.onInit   
    ;User defined skin   
    ;SetOutPath $TEMP   
    ;File /oname=Skinastic.skf "Skinastic.skf"  
    ;NSIS_SkinCrafter_Plugin::skin /NOUNLOAD $TEMPSkinastic.skf   
    ;Delete $TEMPSkinastic.skf   
  
    ;Default Skin   
    NSIS_SkinCrafter_Plugin::skin /NOUNLOAD   
FunctionEnd   
  
Function un.onGUIEnd   
 NSIS_SkinCrafter_Plugin::destroy   
FunctionEnd   
  
;--------------------------------   
;Include Modern UI   
  
  !include "MUI.nsh"  
  
;--------------------------------   
;General   
  
  ;Name and file   
  Name "NSIS SkinCrafter Plugin Test"  
  OutFile "sample.exe"  
  
  ;Default installation folder   
  InstallDir "$PROGRAMFILESNSIS SkinCrafter Plugin Test"  
  
  ;Get installation folder from registry if available   
  InstallDirRegKey HKCU "SoftwareNSIS SkinCrafter Plugin" ""  
  
;--------------------------------   
;Interface Settings   
  
  !define MUI_ABORTWARNING   
  
;--------------------------------   
;Pages   
  
  !insertmacro MUI_PAGE_COMPONENTS   
  !insertmacro MUI_PAGE_DIRECTORY   
  !insertmacro MUI_PAGE_INSTFILES   
  
  !insertmacro MUI_UNPAGE_CONFIRM   
  !insertmacro MUI_UNPAGE_INSTFILES   
  
;--------------------------------   
;Languages   
  
  !insertmacro MUI_LANGUAGE "English"  
  
;--------------------------------   
;Installer Sections   
  
Section "Dummy Section" SecDummy   
  
  SetOutPath "$INSTDIR"  
  
  ;ADD YOUR OWN FILES HERE...   
  
  ;Store installation folder   
  WriteRegStr HKCU "SoftwareNSIS SkinCrafter Plugin" "" $INSTDIR   
  
  ;Create uninstaller   
  WriteUninstaller "$INSTDIRUninstall.exe"  
  
SectionEnd   
  
;--------------------------------   
;Descriptions   
  
  ;Language strings   
  LangString DESC_SecDummy ${LANG_ENGLISH} "A test section."  
  
  ;Assign language strings to sections   
  !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN   
    !insertmacro MUI_DESCRIPTION_TEXT ${SecDummy} $(DESC_SecDummy)   
  !insertmacro MUI_FUNCTION_DESCRIPTION_END   
  
;--------------------------------   
;Uninstaller Section   
  
Section "Uninstall"    
  ;ADD YOUR OWN FILES HERE...     
  Delete "$INSTDIRUninstall.exe"    
  RMDir "$INSTDIR"    
  DeleteRegKey /ifempty HKCU "SoftwareNSIS SkinCrafter Plugin"    
SectionEnd
永恒心锁,版权所有丨如未注明,均为转载丨本网站采用BY-NC-SA协议进行授权

转载请注明:永恒心锁-分享互联网 » NSIS皮肤插件

您必须 登录 才能发表评论!