Skip to content

Commit

Permalink
...
Browse files Browse the repository at this point in the history
:: 2024-12-18 Added: New template — "DualTab Vertical" (Requested in #17).
  • Loading branch information
ramdany7 committed Dec 18, 2024
1 parent c421159 commit 9095d99
Show file tree
Hide file tree
Showing 11 changed files with 449 additions and 8 deletions.
19 changes: 11 additions & 8 deletions RCFI Tools.bat
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@
:: 2024-12-04 Added: Config option to specify the "Collections" folder and the initial directory for the file selection dialog.
:: 2024-12-04 Added: Config option to specify the template to use for images from the "Collections" folder (including its subfolders).
:: 2024-12-04 Improved: Logic to skip the "TemplateAlwaysAsk" dialog when conditions for "TemplateFor" are met.
:: 2024-12-05 Improved: Removed unused lines, reorganized code, and optimized performance (possibly creating some bugs too 😅).
:: 2024-12-05 Improved: Right-click 'Change Folder Icon' now opens the file selection dialog.
:: 2024-12-06 Modified: Changed default settings to TemplateAlwaysAsk="Yes", TemplateIconSize="Auto", HideAsSystemFiles="Yes".
:: 2024-12-05 Improved: Removed unused lines, reorganized code, and optimized performance (possibly introduced a few bugs 😅).
:: 2024-12-05 Improved: Right-clicking 'Change Folder Icon' now opens the file selection dialog.
:: 2024-12-06 Modified: Updated default settings to TemplateAlwaysAsk="Yes", TemplateIconSize="Auto", and HideAsSystemFiles="Yes".
:: 2024-12-07 Fixed: Convert.exe failing to generate icons when using the 'generate' feature.
:: 2024-12-09 Fixed: Unable to open 'Global Template Configuration' from the Template Configurations menu.
:: 2024-12-10 Fixed: Some folder names not displaying correctly when generating icons.
:: 2024-12-10 Fixed: Some folder names not displaying correctly during icon generation.
:: 2024-12-18 Added: New template — "DualTab Vertical" (Requested in #17).

setlocal
set name=RCFI Tools
Expand Down Expand Up @@ -500,8 +501,9 @@ for /f "tokens=1-12 delims=," %%A in ("%ImageSupport%") do (
set "fileFilter=Image Files (*.jpg, *.png, *.ico, ...)|%fileFilter%"
set "OpenFileSelector=Add-Type -AssemblyName System.Windows.Forms; $f = New-Object System.Windows.Forms.OpenFileDialog; $f.InitialDirectory = '%initialDirectory%'; $fileDialog.RestoreDirectory = $true; $f.Filter = '%fileFilter%'; $f.ShowDialog() | Out-Null; $f.FileName; exit"
if /i "%FS-Trigger%"=="Context" (
echo.&echo.&echo.&echo.&echo.&echo.&echo.&echo.&echo.&echo.
echo %I_%%G_% Select a file from the file selection dialog %_%
echo.&echo.&echo.&echo.&echo.&echo.&echo.&echo.&echo.&echo.
echo %I_%%G_% Select a file from the file selection dialog %_%
set "FS-Trigger="
)
start /MIN /WAIT "" "%RCFI%\resources\File_Selector.bat"

Expand Down Expand Up @@ -591,7 +593,7 @@ if not exist "%input%" (
set "Input=%Input:"=%"
if /i "%input%"=="1" goto FI-Selected_folder-Separate
if /i "%input%"=="o" set "FS-referer=Choose.from.collections"&goto FI-File_Selector
if /i "%input%"=="c" set "initialDirectory=%CollectionsFolder%"&set "FS-Trigger=Context"&set "FS-referer=Change.Folder.Icon"&goto FI-File_Selector
if /i "%input%"=="c" set "initialDirectory=%CollectionsFolder%"&set "FS-referer=Change.Folder.Icon"&goto FI-File_Selector
echo.
if not exist "%Input%" (
echo.
Expand Down Expand Up @@ -2939,7 +2941,8 @@ ping localhost -n 2 >nul
EXIT

:FI-Updater
for /l %%N in (1,1,4) do (
for /l %%N in (1,1,1) do (
%P2%
for /f "usebackq tokens=* delims=" %%F in ("%RCFI%\resources\FolderUpdater_list.txt") do (
call "%FI-Update%" /f %%F >nul 2>&1 &call |EXIT /B
)
Expand Down
Binary file added images/DualTabV-DropShadow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/DualTabV-Front.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/DualTabV-FrontFX.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/DualTabV-Tab1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/DualTabV-Tab1FX.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/DualTabV-Tab2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/DualTabV-Tab2FX.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added resources/BIG_NOODLE_TITLING.ttf
Binary file not shown.
65 changes: 65 additions & 0 deletions resources/custom_foldername.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
@echo off
chcp 65001 >nul
for %%F in ("%cd%") do set "foldername=%%~nxF"
set "InputFolderName=_0"
set "InputLogo=_0"
set "custom-FolderName-HaveTheLogo="
title Custom folder name for "%FolderName%"
echo.
echo.
echo %W_%%I_% Custom Folder Name %_%
echo.
echo %TAB%Folder Name: %ESC%%YY_%%FolderName%%ESC%
echo %TAB%Template : %ESC%%CC_%%Templatename%%ESC%
echo.
echo.
echo %_%%G_%%G_%Press "%C_%O%G_%" and hit Enter to %C_%open%G_% the file selection dialog.%_%
echo %_%%G_%%G_%Press "%C_%C%G_%" and hit Enter to open the %C_%Collections%G_% folder.%_%
echo %_%%G_%You can also %PP_%drag and drop%_%%G_% an %C_%image%G_% into this window.%_%
echo %_%%G_%Leave it empty to skip and use the default settings.%_%
echo.
echo %W_%%G_%Enter a folder name or an image file path:
set /p "InputFolderName=%W_% %_%%C_% "
set "InputFolderName=%InputFolderName:"=%"
if exist "%cfn1%" del /q "%cfn1%"

if /i "%InputFolderName%"=="o" call :file_selector

if /i "%InputFolderName%"=="_0" (
echo %G_%%I_% Skipped %_%
echo set "custom-FolderName=No">>"%cfn1%"
goto exit
)
if /i "%InputFolderName%"=="." goto empty
if /i "%InputFolderName%"==" " goto empty
if /i "%InputFolderName%"=="_" goto empty

if exist "%InputFolderName%" for %%I in ("%InputFolderName%") do (
for %%X in (%ImageSupport%) do if "%%X"=="%%~xI" (
echo set "Logo=%%~fI">>"%cfn1%"
echo set "LogoName=%%~nxI">>"%cfn1%"
echo set "use-Logo-instead-FolderName=Yes">>"%cfn1%"
echo set "custom-FolderName-HaveTheLogo=Yes">>"%cfn1%"
goto exit
)
)
echo set "foldername=%InputFolderName%">>"%cfn1%"
echo set "display-FolderName=Yes">>"%cfn1%"
echo set "use-Logo-instead-FolderName=No">>"%cfn1%"
goto exit

:empty
echo set "display-FolderName=no">>"%cfn1%"
echo set "use-Logo-instead-FolderName=no">>"%cfn1%"
goto exit

:exit
if /i not "%multi-FolderName%"=="yes" exit
set "InputFolderName2="
echo.
echo %W_%%G_%Enter the second folder name, or leave it empty to skip:
set /p "InputFolderName2=%W_% %_%%C_% "
type nul "%cfn2%"
set InputFolderName2=%InputFolderName2:"=%
if defined InputFolderName2 echo "%InputFolderName2%">>"%cfn2%"
exit
Loading

0 comments on commit 9095d99

Please sign in to comment.