• Intro to AutoHotkey HotStrings with AutoHotkey Intermediate AutoHotkey GUIs are Easy with AutoHotkey Intro to DOS & AutoHotkey

How to trim whitespace in SciTE: #1 hack to clean your code!

trim whitespace in SciTE

How to Automatically trim whitespace in SciTE upon file save is super-easy!   A minor tweak to the trim whitespace in SciTEuser.properties will tell SciTE to, automatically, trim spaces, tabs, etc. from the end of each line.

The following example is what I added to have it apply to my AutoHotkey files (which have an extension of .ahk).  If you have file patterns you can achieve the same goal by using something like this:

strip.trailing.spaces.$(file.patterns.yaml)=0

strip.trailing.spaces.*.ahk=1

How to trim whitespace in SciTE upon file save

AutoHotkey Bottle 4

How to create your own Custom SciTE Hotkeys by hacking your SciTE user.properties file

Custom SciTE Hotkeys

Creating custom SciTE Hotkeys are a great way to speed-up working in SciTE!

I highly recommend you download and print out these built-in SciTE4AutoHotkey hotkeys

Hotkeys are a great way to be more efficient!  AutoHotkey makes it easy to create a hotkey for nearly anything however you can easily create your own custom SciTE Hotkeys by making a tweak to your user.properties file.

Below is the text I have in my user.properties file which builds in hotkeys without needing AutoHotkey.  You can find additional commands by going here.  Just don’t forget you are not limited to these.  In the video I show how you can create your own!  Make sure you do not have any comments within your list.  In my video I have them but I realized, later, that this causes issues.

btw- To be able to highlight text and move it up or down you can add
Ctrl+Shift+Up|2620|\
Ctrl+Shift+Down|2621|\

This video walks through creating your own Custom SciTE Hotkeys

How to Run selected text in SciTE- Great tip for long AutoHotkey scripts

Running selected text in SciTE

How to Run selected text in SciTE

When working on longer AutoHotkey scripts, I love being able to just highlight some text and run only it.  This is possible from making some tweaks to your User.Properties file and using this file by JoeDF.

Here is the text you’ll add to your User.Properties file:
Use the following for a webpage post:

Or you can download this AutoHotkey script

In the below video I walk through how to make updates to the User.Properties file as well as demonstrate Running selected text in SciTE.

Configuring SciTE Property files- IntelliSense for 79 languages

Configuring SciTE language Property filesConfiguring SciTE language Property files

One of the main reasons I love SciTE is because of the ability to use the ~70 language property files which show Intellisense.  I’ve put around 70 of them in this zip file and I’ve listed out the names of them at the bottom of this post.

Configure SciTE language Property files is easy.  In your User.Properties file just add something like this

import Properties\html
import Properties\sql
import Properties\python

The Properties folder needs to be either in the same directory as where SciTE is installed, or needs to be located in the folder where you have configured your SciTE Home variable to point to.

After importing the properties you want, I also recommend importing them to your language menu as well.  This way you can select what language you want to apply to the open file (this can come in pretty handy at times).  To do this you’ll still need to be in your User.Properties file.  Add something like below.  (The & is what will make that letter become an accelerator key)

menu.language=\
&HTML|html||\
S&ql|sql||\
&Py|Python||

And here are some notes to help understand what can be done when Configuring SciTE language Property files:

#****************language***************************************.
# Define the Lexer menu, Each item contains three parts: menu string | file extension | keyboard equivelant
# The only keys allowed currently are based on F-keys and alphabetic keys and look like # [Ctrl+][Shift+][Fn|a] such as F12 or Ctrl+Shift+D.
# A ‘&’ may be placed before a letter to be used as an accelerator. Each element is terminated by ‘|’. For example: H&ypertext|html|F12|

Here are the language property files provided in my zip file.

abaqus escript nimrod smalltalk
asn1 flagship nncrontab sorcins
au3 forth nsis specman
ave fortran opal spice
baan freebasic others spss
blitzbasic gap pascal sql
bullant haskell perl tacl
caml html pov tal
cmake inno powerpro tcl
cobol kix powershell tex
conf latex ps txt2tags
cpp lisp purebasic vb
csound lot python verilog
css lout r vhdl
d matlab rebol yaml
debug.py metapost ruby
eiffel mmixal SciTEUser
erlang modula3 scriptol
  • Intro to AutoHotkey HotStrings with AutoHotkey Intermediate AutoHotkey GUIs are Easy with AutoHotkey Intro to DOS & AutoHotkey