DamEdit (or actull Damavand Code Editor) is a lightweight, config-driven Python code editor built with Tkinter. It offers syntax highlighting, line numbers, a file browser sidebar, customizable themes, and a built-in search dialog, providing a minimal yet functional environment for Python development.
- 🎨 Syntax Highlighting
- Built-in Python support
- Load custom language configs (
configs/*.json) - Regex-based or keyword-based highlighting
- 🎨 Themes
- Built-in dark theme
- Load custom theme JSONs dynamically
- Reset to default theme
- 📂 File Management
- Open, Save, Save As
- File sidebar for browsing current directory
- 📝 Editor Utilities
- Line numbers with automatic updates
- Highlight current line
- Increment/decrement font size
- 🔍 Search
- Find next/previous in the editor
- Highlight search matches
- 🖥️ UI
- Toolbar with file, programming language, theme, and find options
- Scrollbars synchronized with text area and line numbers
- Cross-platform (Windows, Linux)
- Clone the repository:
git clone https://github.com/Artin-khodayari/DamEdit.git
cd DamEdit-
Ensure Python 3.10+ is installed.
-
Run the editor:
python main.py- Open a file:
File → OpenorCtrl+O - Save a file:
File → SaveorCtrl+S - Save As:
File → Save AsorCtrl+Shift+S - Change language:
Language → Load language JSON... - Change theme:
Theme → Load Theme JSON... - Find text:
Ctrl+ForFind button - Increase/decrease font size:
Ctrl + / Ctrl -
The editor automatically detects language config based on file extension. If no config exists, it defaults to Python highlighting for .py files.
-
Place language configs in the
configs/folder (JSON format). -
Language JSON can define:
type:"python"or"regex"keywords: dictionary of tag → word listpatterns: regex-based highlighting rulesthemeorcolors: optional color overridesextensions: file extensions it applies to
-
Themes are JSON files mapping editor tags to hex colors:
{
"editor_bg": "#1C1B21",
"editor_fg": "#D8D8D8",
"control": "#569CD6",
"string": "#F29E74"
}- Minimal dark-themed design
- Sidebar for file navigation
- Active-line highlighting
- Custom scrollbars and styled buttons
- Separate find window with search controls
Contributions are welcome!
- Fork this repository
- Create a feature branch (
git checkout -b feature-name) - Make your changes
- Commit (
git commit -am 'Add new feature') - Push (
git push origin feature-name) - Open a Pull Request
This project is made by Artin Khodayari.
You can contact me and report bugs via Gmail.
This project is licensed under the MIT License.
