1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
|
# Installation
## Requirements
In its bid for minimalism, Textadept also depends on very little to run. The GUI
version needs only [GTK+][], a cross-platform GUI toolkit, version 2.18 or later
on Linux and BSD systems. The application already bundles a GTK+ runtime into
the Windows and Mac OSX packages. The terminal, or curses, version of Textadept
only depends on a curses implementation like [ncurses][] on Linux, Mac OSX, and
BSD systems. The Windows binary includes a precompiled version of [pdcurses][].
Textadept also incorporates its own [copy of Lua][] on all platforms.
[GTK+]: http://gtk.org
[copy of Lua]: 11_Scripting.html#Lua.Configuration
[ncurses]: http://invisible-island.net/ncurses/ncurses.html
[pdcurses]: http://pdcurses.sourceforge.net
### Linux and BSD
Most Linux and BSD systems already have GTK+ installed. If not, your package
manager probably makes it available. Otherwise, compile and install GTK+from the
[GTK+ website][].
The Linux binaries for the GUI versions of Textadept require GLib version 2.28
or later to support [single-instance](#Single.Instance) functionality. However,
Textadept compiles with versions of GLib as early as 2.22. For reference, Ubuntu
11.04, Debian Wheezy, Fedora 15, and openSUSE 11.4 support GLib 2.28 or later.
Most Linux and BSD systems already have a curses implementation like ncurses
installed. If not, look for one in your package manager, or compile and install
ncurses from the [ncurses website][]. Ensure it is the wide-character version of
ncurses, which handles multibyte characters. Debian-based distributions like
Ubuntu typically call the package "libncursesw5".
[GTK+ website]: http://www.gtk.org/download-linux.html
[ncurses website]: http://invisible-island.net/ncurses/#download_ncurses
### Mac OSX
No requirements other than Mac OSX 10.5 (Leopard) or higher with an Intel CPU.
### Windows
No requirements.
## Download
Download Textadept from the project's [download page][] by selecting the
appropriate package for your platform. For the Windows and Mac OSX packages, the
bundled GTK+ runtime accounts for more than 3/4 of the download and unpackaged
application sizes. Textadept itself is much smaller.
You also have the option of downloading an official set of [language modules][]
from the download page. Textadept itself includes C/C++ and Lua language modules
by default.
[download page]: http://foicica.com/textadept/download
[language modules]: 07_Modules.html#Language.Modules
## Installation
Installing Textadept is simple and easy. You do not need administrator
privileges.
### Linux and BSD
Unpack the archive anywhere.
If you downloaded the set of language modules, unpack it where you unpacked the
Textadept archive. The modules are located in the
*/path/to/textadept_x.x/modules/* directory.
### Mac OSX
Unpack the archive and move *Textadept.app* to your user or system
*Applications/* directory like any other Mac OSX application. The package
contains an optional *ta* script for launching Textadept from the command line
that you can put in a directory in your "$PATH" (e.g. */usr/local/bin/*).
If you downloaded the set of language modules, unpack it, right-click
*Textadept.app*, select "Show Package Contents", navigate to
*Contents/Resources/modules/*, and move the unpacked modules there.
### Windows
Unpack the archive anywhere.
If you downloaded the set of language modules, unpack it where you unpacked the
Textadept archive. The modules are located in the *textadept_x.x\modules\\*
directory.
## Running
### Linux and BSD
Run Textadept by running */path/to/textadept_x.x/textadept* from the terminal
You can also create a symbolic link to the executable in a directory in your
"$PATH" (e.g. */usr/local/bin/*) or make a GNOME, KDE, XFCE, etc. button or menu
launcher.
The package also contains a *textadeptjit* executable for running Textadept with
[LuaJIT][]. Due to potential [compatibility issues][], use the *textadept*
executable wherever possible.
The *textadept-curses* and *textadeptjit-curses* executables are the terminal
versions of Textadept. Run them as you would run the *textadept* and
*textadeptjit* executables, but from a terminal instead.
[LuaJIT]: http://luajit.org
[compatibility issues]: 11_Scripting.html#LuaJIT
#### Problems
Providing a single binary that runs on all Linux platforms proves challenging,
since the versions of software installed vary widely from distribution to
distribution. Because the Linux version of Textadept uses the version of GTK+
installed on your system, an error like:
error while loading shared libraries: <lib>: cannot open shared object
file: No such file or directory
may occur when trying to run the program. The solution is actually quite
painless even though it requires recompiling Textadept. The [compiling][] page
has more information.
[compiling]: 12_Compiling.html
### Mac OSX
Run Textadept by double-clicking *Textadept.app*. You can also pin it to your
dock.
*Textadept.app* also contains an executable for running Textadept with
[LuaJIT][]. Enable it by setting a "TEXTADEPTJIT"
[environment variable](#Environment.Variables) or by typing
`export TEXTADEPTJIT=1` in the terminal. Due to potential
[compatibility issues][], use the non-LuaJIT executable wherever possible.
[LuaJIT]: http://luajit.org
[compatibility issues]: 11_Scripting.html#LuaJIT
#### Environment Variables
By default, Mac OSX GUI apps like Textadept do not see shell environment
variables like "$PATH". Consequently, any [modules][] that utilize programs
contained in "$PATH" (e.g. the progams in */usr/local/bin/*) for run and compile
commands will not find those programs. The solution is to create a
*~/.textadept/osx_env.sh* file that exports all of the environment variables you
need Textadept to see. For example:
export PATH=$PATH
[modules]: 07_Modules.html
### Windows
Run Textadept by double-clicking *textadept.exe*. You can also create shortcuts
to the executable in your Start Menu, Quick Launch toolbar, Desktop, etc.
The package also contains a *textadeptjit.exe* executable for running Textadept
with [LuaJIT][]. Due to potential [compatibility issues][], use the
*textadept.exe* executable wherever possible.
[LuaJIT]: http://luajit.org
[compatibility issues]: 11_Scripting.html#LuaJIT
### *~/.textadept*
Textadept stores all of your preferences and user-data in your *~/.textadept/*
directory. If this directory does not exist, Textadept creates it on startup.
The manual gives more information on this folder later.
## Single Instance
Textadept is a single-instance application on Linux, BSD, and Mac OSX. This
means that after starting Textadept, running `textadept file.ext` (`ta file.ext`
on Mac OSX) from the command line or opening a file with Textadept from a file
manager opens *file.ext* in the original Textadept instance. Passing a `-f` or
`--force` switch to Textadept overrides this behavior and opens the file in a
new instance: `textadept -f file.ext` (`ta -f file.ext`). Without the force
switch, the original Textadept instance opens files, regardless of the number of
instances open.
The Windows and terminal versions of Textadept do not support single instance.
<span style="display: block; text-align: right; margin-left: -10em;">
![Linux](images/linux.png)
![Mac OSX](images/macosx.png)
![Win32](images/win32.png)
![curses](images/ncurses.png)
</span>
|