Subscribe to the RSS Feed.
Aesthetically pleasing, Dracula PRO is a color scheme and UI theme tailored for programming.
πδΈζη
If you are a git user, you can install the theme and keep up to date by cloning the repo:
git clone https://github.com/dracula/texworks.git
Download using the GitHub .zip download option and unzip them.
Extract syntax-patterns.txt
(syntax highlighting settings), theme.css
(QSS configuration), and the src
folder (icon assets), which are the necessary theme files
Find TeXworks' resource directory <Resources>
.
βΉοΈ Note A
You can open TeXworks editor if you don't know where the resource directory is:Help
->Settings and Resources...
->Resources
<Resources>/configuration
:mv syntax-patterns.txt theme.css src "<Resources>/configuration"
βΉοΈ Note B
syntax-patterns.txt
can not be renamed or put on other paths! Its eponymous file already exists in<Resources>/configuration
. This is the default file. You'd better back up the default file before overwriting.
<YourTeXworksPath>/texworks -stylesheet "<Resources>/configuration/theme.css"
βΉοΈ Note C
theme.css
andsrc
can be renamed or have their storage paths changed as long as the path changes are correct. If you decide to do so, don't forget that all the icon paths in the renamed .css file need to be changed as well.
If you find it inconvenient to manually add the optional -stylesheet
argument every time you launch TeXworks from the command line, you can follow the steps below for a more permanent solution.
β Caution
If you plan to modify global settings, make sure to back up any relevant files beforehand!
Windows
Right-click on TeXworks' shortcut file and select Properties
. Then update the content in the Target
input field to:
<YourTeXworksPath>\texworks.exe -stylesheet "<Resources>\configuration\theme.css"
This ensures that the theme is applied every time you launch TeXworks via the shortcut. However, opening .tex files directly will still require modifying the global settings.
To do this, you need to run the Registry Editor
as an administrator
and modify the registry entry for your TeX distribution (usually located under Computer\HKEY_CLASSES_ROOT
).
The following structure shows the example path for MiKTeX:
MiKTeX.tex.2.9
βββ DefaultIcon
βββ shell
βββ open
βββ command
Navigate to the registry key:
Computer\HKEY_CLASSES_ROOT\MiKTeX.tex.2.9\shell\open\command
Edit or create a new string value (type: REG_SZ) and set its data to:
<YourTeXworksPath>\miktex-texworks.exe -stylesheet "<Resources>\configuration\theme.css" "%1"
After completing these steps, the theme will be enabled globally for TeXworks. You can similarly apply these global settings to other file types such as .pdf and .bib files by performing the same modification on their corresponding registry keys (e.g. MiKTeX.pdf.2.9
and MiKTeX.bib.2.9
).
Linux or macOS:
To launch TeXworks in the theme by default, you can create an alias in your shell configuration file (e.g. .bashrc
, .zshrc
, or .profile
on macOS):
alias texworks='texworks -stylesheet "/path/to/darkbg.css"'
After saving the changes, reload your shell configuration with
source ~/.bashrc # or the respective file
and the alias will be ready to use.