I have developed this button to improve its efficiency and flexibility. The exercise has forced me to expand my skills using DOPUS' extensive capabilities. It has been rewarding to get things to work. I will describe how I created it and the internal commands I have used to help others realise that they can shape DOPUS to their needs and preferences.
I am not a programmer and welcome comments or pointers to improve on what I have produced. Developers and programmers have learnt and practised their skills to the point of taking them for granted and do not need to reiterate the detailed steps and logic behind their work. We all do it. For example, we followed extensive steps and rules when we first learnt to drive. After practice and experience, many of us can drive a car without consciously remembering each step. When we try to teach others to drive, we struggle to relay all the finer steps we take for granted. We all need teachers who can teach us the basic steps, using creative methods to help us step up and confidently drive DOPUS.
Background to the Button
A new DOPUS user, identified as r47926, asked if it was possible to set up DOPUS to show PDF files he had opened and organised from the latest to the earliest order. He specified that he would like to select and view these files as thumbnails, open the files, and delete the files from the view. Furthermore, he realised that the solution might apply to other file formats (e.g. docx, xlsx, odt, etc).
DOPUS developer Leo swiftly offered some suggestions and possible caveats to creating a DOPUS button using internal commands:
Go /recent Set QUICKFILTER=*.pdf
r47926 engaged with Leo and successfully implemented a DOPUS button. The discussion also alerted users to set preferences:
Preferences / File Displays / FAYT and Filter Bar Options / Clear Quick filter automatically when changing folders so the
Preferences / Folders / Virtual Folders / Treat all virtual folders as real to filter the "Recent Folder".
Furthermore, ensure that you have set Windows Explorer to show extensions (in the View Menu). Otherwise, the button will not find the links based on their file extension.
After 12 days, r47926 sought further help to refine the button. The talented and helpful user, lxp, provided two internal commands and provided links to the DOPUS help file that explained their use:
Set VIEW=thumbnails Show THUMBNAILSIZE
This led r47926 to publish a satisfactory solution:
Go /recent Set QUICKFILTER=*.(pdf|epub|mobi|azw|djv|djvu).lnk Set VIEW=thumbnails Show THUMBNAILSIZE 256
Extending the Button's Functionality.
After using the button, I decided to adapt it to my needs. After looking at other button constructions listed on the forum and reading the help documentation, I developed the original idea and produced another version of the button.
Recent Files Button
This button defines functionality for the mouse's Centre, Left and Right buttons. Left and Right buttons act as toggles (see below).
First, the user should design their preferred DOPUS layout and save it by using the Centre Button of the mouse to click the button. This action opens a "Save Layout: dialogue box, allowing the user to name and save the current layout. Use "My Lister" as the layout name since the button uses this name to open your preferred layout. Users can use any name they like but be sure to change the name in the button code.
Second, the user must define the Lister layout for the Windows "Recent" folder. When complete, save it by using the Centre Button of the mouse to click the button and save as "Recent Files". Select the first box at the bottom of the dialogue to ensure other layouts/listers are closed when this layout is opened. I use the following layout, closing the Folder Tree, opening the Viewer, arranging the layout on the screen, and sorting by the "Modified" column. You can also choose thumbnail view and size from the Lister, but the button will also set this up.
Left Mouse Button
Left-clicking the button uses DOPUS internal commands to open the predefined "Recent Files" Layout displayed as 256px thumbnails and descending from the latest open file. The viewer is opened on the right side of the DOPUS window.
Left-clicking again opens the "My Lister" Layout, returning DOPUS to your preferred layout.
@toggle:if $glob:MyToggle @ifset:$glob:MyToggle Prefs LAYOUT="My Lister" @set glob:MyToggle @ifset:else Prefs LAYOUT="Recent Files" Show THUMBNAILSIZE 256 Set QUICKFILTER=*.(pdf|epub|mobi|azw|djv|djvu|docx).lnk @set glob:MyToggle=1
Right Mouse Button
Right-clicking the button uses DOPUS internal commands to save your current lister layout as "StartLayout" and then replaces it with the predefined "Recent Files" Layout.
Left-clicking again opens the "StartLayout" Layout, returning DOPUS to the layout you started with.
@toggle:if $glob:MyToggle @ifset:$glob:MyToggle Prefs LAYOUT="StartLayout" @set glob:MyToggle @ifset:else Prefs LAYOUTNAME="StartLayout" LAYOUTSAVE LAYOUTCLOSELISTERS=yes Prefs LAYOUT="Recent Files" Show THUMBNAILSIZE 256 Set QUICKFILTER=*.(pdf|epub|mobi|azw|djv|djvu|docx).lnk @set glob:MyToggle=1
Recent-PrefL.dcf (2.2 KB)
Right-click on a space in a DOPUS toolbar and
select Customize. Then,
drag this button file to a position of your choice.