Skip to content

About

A Windows application that actually search Windows for files! What an idea? Also a Windows 11 Notepad replacement and a few other miscellaneous utilites.

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

Ace's Utilities (AceUtils)

"A Windows application that actually search Windows for files! What an idea? Also a Windows 11 Notepad replacement and a few other miscellaneous utilites."

Platform Framework License

Ace's Utilities (AceUtils) is a high-performance, lightweight desktop power tool written in Object Pascal using the Free Pascal Compiler (FPC) and Lazarus LCL. While tailored for modern Windows workflows, the entire codebase is written using portable LCL components and clean conditional directives, allowing it to be compiled and run on Linux very easily.

It also takes back the .txt and .md associations Windows keeps STEALING. No admin rights, no registry surgery on your end.


✨ Key Features

⚡ 1. Context Menu Management & Windows 11 Association Takeover

Microsoft keeps hijacking file associations in Windows 11 using hidden UserChoice / UserChoiceLatest registry keys, forcing files to open in modern UWP Notepad even after you set your defaults. Ace's Utilities fixes this once and for all:

  • Take Back Stolen File Associations: Reclaims .txt, .md, and .markdown defaults with a single click. Wipes out the Windows 11 UserChoiceLatest hijack, registers clean ProgIDs, and broadcasts shell notifications—100% per-user with zero admin rights and zero reboots.
  • Per-User Shell Verb Scanner: Audits all registered context menu entries in HKCU\Software\Classes across * (all files), Directory (folders), Background, .txt, .md, and registered Applications.
  • Stale / Orphaned Entry Detection: Automatically parses target commands and inspects the filesystem to flag dead entries whose executables no longer exist (e.g., from uninstalled or renamed apps).
  • One-Click Stale Purge: Instantly cleans out all orphaned shell verbs in one click.
  • Edit & Remap Commands: Modify display labels and repoint command-line paths for any user context menu item directly from the UI.
  • Context Menu Toggle: Add or remove "Open with Ace's Utilities" from Explorer right-click menus on the fly.
  • Headless CLI Registration: Supports /register and /unregister flags for silent scripting or automated deployment.

🔍 2. Real Windows File Search (That Actually Works)

Tired of Windows Search indexing freezes, search loops, or failing to find files that are right in front of you?

  • Fast Traversal Engine: Safe Breadth-First Search (BFS) directory walker.
  • Instant & Non-Blocking Stop: Responsive UI polling every 50ms ensures clicking "Stop" cancels deep searches instantaneously without freezes or Windows "(Not Responding)" lockups.
  • Pre-Parsed Pattern Engine: Pattern lists are compiled once per search, eliminating per-file memory churn and boosting traversal speeds.
  • Smart Directory Detection: Pasting a full file path (or quoted path) into the search directory field automatically resolves to its parent folder.
  • Junction Point & Symlink Protection: Automatically skips NTFS reparse points (FILE_ATTRIBUTE_REPARSE_POINT $400), avoiding endless recursion loops common in Windows 11 user directories (e.g. Application Data).
  • Flexible Pattern Matching: Type *.pas or simply MainForm—terms without explicit wildcards automatically perform substring searches. Multiple patterns can be delimited by semicolons (*.pas;*.lpr;*.md).
  • Content Search: Full-text scanning inside files with configurable case sensitivity and graceful stopping.
  • Interactive Multi-Column Header Sorting: Click any column (File Name, Folder, Size, Modified Date, Type) to sort Ascending (▲) or Descending (▼). File sizes sort by true numeric byte count (so 10 MB correctly sorts higher than 2 KB).
  • Directory Tree & Quick Buttons: Includes a full TShellTreeView, directory browse dialog, and one-click quick jump buttons for C:\, User Home, and Desktop.
  • Rich Results Context Menu: Right-click any search result to Open in Notepad, Reveal in Explorer, Open / Run File, Copy Filename Only, Copy File Path Only, or Copy File Path and Name (with multi-item selection clipboard support).

📁 3. The Real Explorer

Frustrated by modern Windows Explorer hiding folders or switching views? The Real Explorer provides a fast, permanent classic file manager:

  • Folders First & Permanent Details View: Reliable directory navigation where folders always stay grouped at the top and detailed columns (Name, Size, Modified, Type) stay fixed.
  • Smart Address Bar: Paste full file paths, filenames, or quoted paths (e.g. "C:\Users\User\Desktop\unfollow-day1.md" or C:\file.txt) directly into the path edit. The Explorer intelligently detects whether the input is a file or folder, navigates to the parent directory, auto-selects the file in the list, and opens it in the floating Live Preview window.
  • Full Navigation Stack: Back, Forward, Up, and Refresh buttons with dynamic history management.
  • Quick Jump Chips: One-click jump buttons for Desktop, Downloads, Documents, Pictures, Drive C:\, and User Home.
  • Custom Default Startup Folder: Set your favorite starting location (e.g., Desktop or Project root) with a single click of "Set Default".
  • Floating Preview & Context Actions: Dedicated Preview button, Recycle Bin deletion, in-place rename, and seamless "Open in Notepad" tab routing.

👁️ 4. Floating Live File Preview Window

Preview files dynamically on a single click without blocking the main search window:

  • Modeless Floating Window: Stays open side-by-side with your search list; click any result and the preview updates instantaneously.
  • Image Previews: Seamless native rendering for .png, .jpg, .jpeg, .bmp, .ico, and .gif with proportional scaling, dimension readouts (Width x Height), and file size.
  • Syntax-Highlighted Code & Text Previews: Read-only TSynEdit preview displaying the first 300 lines with line numbers and auto-detected syntax coloring for Pascal, Python, HTML/XML, CSS, JavaScript, JSON, SQL, Batch, INI, and Markdown.
  • Binary & Document File Cards: Displays the high-resolution Windows Shell icon (SHGetFileInfo), file metadata, and a 16-column Hex + ASCII byte peek of the file header.
  • "Open in Editor" Quick Action: One click jumps straight into the built-in Notepad editor tab.
  • Enable / Disable Toggle: Easily toggle live preview on or off with the search option checkbox.

📝 5. Windows 11 Notepad Replacement

A complete, tabbed text and code editor powered by TSynEdit:

  • File Management: New, Open, Save, and Save As with dirty-tracking prompts so you never lose unsaved changes. Empty or blank files can also be created and saved directly.
  • Multi-Language Syntax Highlighting: Features 20 comprehensive syntax highlighters:
    • Pascal / Delphi / Free Pascal (.pas, .pp, .lpr, .inc, .dpr)
    • Python (.py, .pyw, .pyi)
    • JavaScript, TypeScript & JSON (.js, .jsx, .ts, .tsx, .json, .json5)
    • HTML & Web Templates (.html, .htm, .vue, .svelte, .twig)
    • XML & SVG (.xml, .svg, .xaml, .plist, .csproj, .config)
    • CSS & Stylesheets (.css, .scss, .sass, .less)
    • PHP (.php, .phtml)
    • C, C++, C# & Arduino (.c, .cpp, .h, .hpp, .cs, .ino)
    • Java, Kotlin & Groovy (.java, .kt, .kts, .gradle)
    • SQL & Databases (.sql, .ddl, .pgsql, .sqlite)
    • Windows Batch (.bat, .cmd)
    • INI, Config, YAML & TOML (.ini, .cfg, .conf, .toml, .yaml, .yml, .editorconfig)
    • Unix Shell Scripts (.sh, .bash, .zsh)
    • Perl (.pl, .pm)
    • Visual Basic (.vb, .vbs, .bas)
    • Unified Diff & Patches (.diff, .patch)
    • TeX & LaTeX (.tex, .ltx)
    • Lazarus / Delphi Forms (.lfm, .dfm)
    • Gettext PO Catalogs (.po, .pot)
    • Dedicated Custom Markdown Highlighter (.md, .markdown, .mdown) with real-time styling for headers, code blocks, lists, blockquotes, links, and bold/italic markup.
  • Full Keyboard & Editing Fidelity: Standard Backspace, Delete, Word-Backspace (Ctrl+Backspace), Select All (Ctrl+A), Save (Ctrl+S), Save As (Ctrl+Shift+S), and modern cursor navigation with immediate focus transfer on tab navigation.
  • Find & Replace Bar: Sleek slide-down search bar with Find Next, Replace, Replace All, Case Sensitivity, and Whole Word matching.
  • Word Wrap & Formatting: Toggle Word Wrap on and off on the fly.
  • Text & HTML List Formatting: Format lines instantly as numbered or bulleted lists via toolbar buttons or context menu (Format):
    • Numbered List: Prefixes lines as an ordered list (1. Item, 2. Item), preserving blank lines and automatically stripping prior numbering/bullets so you can renumber or switch formats easily.
    • HTML Option & Unordered Bullet List: Toggle the HTML option to format lines with HTML tags (<ol><li>...</li></ol>) and reveal the Bullet List option for unordered lists (<ul><li>...</li></ul>).
    • Selection-Aware & Atomic Undo: When text is highlighted, formatting applies exclusively to the selected lines; when nothing is highlighted, the entire document is formatted. All format operations support atomic single-step undo (Ctrl+Z).
  • Smart Default File Name on Save: When saving an untitled file, the Save dialog automatically pre-fills a clean 8-character default filename extracted from the first line of text (filtering out Windows and Linux illegal filename characters such as \ / : * ? " < > |), saving user time while preserving full customization.
  • Instant Single-Instance File Opening via Windows Shell: Right-clicking any file in Windows Explorer and choosing "Open with Ace's Utilities", opening associated .txt/.md files, or passing file paths via command line while Ace's Utilities is already running seamlessly opens the file in the active Notepad editor. Powered by high-speed Win32 WM_COPYDATA IPC with window subclassing, elevation filters, automatic system tray unhiding, and dirty-tracking save prompts.
  • Dynamic Document Title Display: The main window title bar dynamically updates with the currently open document (Ace's Utilities - Filename.txt) and dirty flag indicator (Ace's Utilities - *Filename.txt), providing clear document visibility across the Windows taskbar and Alt+Tab switcher.
  • Status Bar: Live line number, column number, character count, UTF-8 indicator, and modified state tracker.

🌙 6. Native Windows 11 Dark Mode

  • Native DWM Titlebar: Integrates directly with Windows 11 Desktop Window Manager (DwmSetWindowAttribute via dwmapi.dll) for a true dark window frame.
  • Automatic System Detection: Detects your Windows theme preference (AppsUseLightTheme) on startup.
  • Dark Mode File Explorer, Results Lists & Grids: Folder trees (ShellTreeViewExplorer and ShellTreeView1) isolate tvoThemedDraw to prevent native Windows black font painting. File listings and grids (ShellListViewExplorer, lvResults, lvMemory, and lvContextMenu) use full custom-drawn items and subitems with high-contrast light silver text ($00F0F0F0 / $00D8D8D8) and deep slate row selections ($006B4D2B).
  • Subclassed Dark Column Titles & Headers: Parent ListView windows intercept Win32 SysHeader32 NM_CUSTOMDRAW notifications, rendering dark slate headers ($0025211E) with crisp light silver column titles ($00F0F0F0) and subtle column separators.
  • Full SynEdit Dark Gutter & Line Numbers: Gutter backgrounds, line numbers, active line highlights, separators, and code-folding parts deeply integrate with the dark palette, delivering high contrast and crystal-clear line number visibility across both the Notepad editor and Live Preview without washed-out light gutter panels.
  • Owner-Drawn Dark Status Bar: High-contrast light text ($00F0F0F0) and active lock indicator styling ($0050D0FF) across all panels, eliminating native Windows SysStatus32 black text on dark backgrounds.
  • One-Click Toggle & Theme Cache Synchronization: Switch seamlessly between Dark and Light mode anytime via the header toggle button. Dynamic custom-draw unhooking, WM_THEMECHANGED cache flushing, and transparent text backgrounds ensure zero stuck dark backgrounds or broken selection highlights when transitioning back to Light Mode.

📥 7. System Tray Integration

  • Run in System Tray: Check the "Run in System Tray" option to keep Ace's Utilities running quietly in your Windows notification area.
  • Minimize & Close to Tray: Minimizing or closing the window cleanly hides it to the tray.
  • Tray Context Menu: Right-click the tray icon for quick actions:
    • Open Ace's Utilities
    • Open Notepad
    • Exit
  • One-Click Restore: Left-clicking the tray icon restores the window to normal view immediately.
  • Persistent Setting: Preferences are saved across restarts in AceUtils.ini.

📑 8. Dynamic Tab Presentation & Styling

  • Multiple Tab Presentation Modes: Switch instantly between Classic Tabs, Modern Flat Buttons, and Push Buttons at runtime via the Tab Style ▾ header dropdown menu.
  • Active Tab Highlight Indicator: Optional dot indicator (●) clearly identifies the currently active notebook page.
  • Spacious / Modern Tab Height: Toggle between compact standard tab sizing and modern 28px touch/desktop tabs.
  • Instant Live Refresh: Seamless Win32 window recreation ensures visual style changes render immediately without requiring an application restart.
  • Persistent Preferences: Saves tab styles, heights, and indicator preferences across sessions in AceUtils.ini.

📋 9. Memory Management & Notes (Clipboard History & Scratchpad)

  • Configurable Manager Dropdown: Easily choose how many clipboard fragments to collect:
    • None: Manager is disabled; cuts and copies are not collected.
    • Last 5 memory (Default): Automatically retains the 5 most recent fragments.
    • Last 4 memory, Last 3 memory, Last 2 memory, or Only one: Keeps precisely the requested history depth.
  • Non-Blocking Clipboard Tracking: Uses Windows clipboard sequence monitoring (GetClipboardSequenceNumber) to detect system-wide cuts and copies without hooks, thread contention, or UI hangs.
  • One-Click Transfer to Notepad: Transfer any memory fragment or note directly into the Notepad tab (inserts at cursor, replaces selection, or appends). Automatically flags the document as unsaved (*Filename.txt or *Untitled Document and Modified status) so changes are never lost.
  • Persistent Quick Notes Scratchpad: A dedicated notes memo on the right side auto-saves directly to AceUtils_Notes.txt and reloads on startup.
  • Rich Context Menu & Actions: Right-click menu and toolbar buttons provide quick options to copy fragments back to the clipboard, append to Quick Notes, delete individual items, clear memory, or transfer to Notepad.

🛠️ Visual Form Designer & Lazarus IDE Compatibility

Both forms are standard Lazarus Component Library (LCL) visual forms:

  • MainForm.lfm / MainForm.pas
  • PreviewForm.lfm / PreviewForm.pas

Every component, panel, gutter, and event handler is declared with standard published properties. You can open, visually modify, and save both forms directly in the Lazarus IDE Form Designer without errors.

🐧 Linux Compilation & Cross-Platform Support

Ace's Utilities is designed from the ground up to be compiled and run on Linux very easily:

  • Conditional Code Separation: All Windows-specific operations (such as Windows DWM dark titlebar composition via dwmapi.dll, Windows Shell file icons via SHGetFileInfo, and Explorer context menu registry integration) are strictly isolated with {$IFDEF WINDOWS} compiler directives.
  • Pure LCL & FPC: The file search engine, breadth-first directory walker, text encoding conversion (LazUTF8 / LConvEncoding), syntax highlighters, and GUI interfaces rely exclusively on the cross-platform Lazarus Component Library (LCL).
  • Multiple Linux Widgetsets: Compiles cleanly against GTK2, GTK3, Qt5, or Qt6 without requiring changes to source code.

Compiling on Linux in 3 Easy Steps

  1. Install Lazarus and FPC:

    # Debian / Ubuntu / Linux Mint
    sudo apt update && sudo apt install lazarus fpc
    
    # Fedora / RHEL
    sudo dnf install lazarus fpc
    
    # Arch Linux / Manjaro
    sudo pacman -S lazarus fpc
  2. Compile with lazbuild:

    lazbuild AceUtils.lpi
  3. Run:

    ./AceUtils

You can also open AceUtils.lpi in the Lazarus IDE on Linux and press F9 to compile and run immediately.


🚀 Building from Source

Prerequisites

  1. Lazarus IDE (version 2.2+ or 3.0+ / 4.0+) with Free Pascal Compiler (FPC 3.2.2+).
  2. SynEdit Package: Standard package bundled with Lazarus (located in lazarus/components/synedit).

Compile via Command Line

Windows (PowerShell / Command Prompt):

lazbuild AceUtils.lpi

Linux (Bash / Zsh):

lazbuild AceUtils.lpi

Compile via Lazarus IDE (Windows or Linux)

  1. Open Lazarus.
  2. Select Project -> Open Project... and choose AceUtils.lpi.
  3. Press F9 (or select Run -> Build).
  4. The compiled executable (AceUtils.exe on Windows, AceUtils on Linux) will be generated in the project root.

📄 License

MIT License. Created by TwilightSurfers.

About

A Windows application that actually search Windows for files! What an idea? Also a Windows 11 Notepad replacement and a few other miscellaneous utilites.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages