Merge branch 'master' into staging
[jackhill/guix/guix.git] / gnu / packages / text-editors.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2016 José Miguel Sánchez García <jmi2k@openmailbox.org>
3 ;;; Copyright © 2016 Carlo Zancanaro <carlo@zancanaro.id.au>
4 ;;; Copyright © 2017, 2018 Eric Bavier <bavier@member.fsf.org>
5 ;;; Copyright © 2017 Feng Shu <tumashu@163.com>
6 ;;; Copyright © 2017 ng0 <ng0@n0.is>
7 ;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.org>
8 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
9 ;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il>
10 ;;; Copyright © 2019 Andreas Enge <andreas@enge.fr>
11 ;;; Copyright © 2019, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
12 ;;;
13 ;;; This file is part of GNU Guix.
14 ;;;
15 ;;; GNU Guix is free software; you can redistribute it and/or modify it
16 ;;; under the terms of the GNU General Public License as published by
17 ;;; the Free Software Foundation; either version 3 of the License, or (at
18 ;;; your option) any later version.
19 ;;;
20 ;;; GNU Guix is distributed in the hope that it will be useful, but
21 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
22 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 ;;; GNU General Public License for more details.
24 ;;;
25 ;;; You should have received a copy of the GNU General Public License
26 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
27
28 (define-module (gnu packages text-editors)
29 #:use-module (guix packages)
30 #:use-module (guix download)
31 #:use-module (guix git-download)
32 #:use-module (guix utils)
33 #:use-module (guix build-system gnu)
34 #:use-module (guix build-system cmake)
35 #:use-module (guix build-system glib-or-gtk)
36 #:use-module (guix build-system python)
37 #:use-module ((guix licenses) #:prefix license:)
38 #:use-module (gnu packages)
39 #:use-module (gnu packages assembly)
40 #:use-module (gnu packages autotools)
41 #:use-module (gnu packages boost)
42 #:use-module (gnu packages documentation)
43 #:use-module (gnu packages fontutils)
44 #:use-module (gnu packages gcc)
45 #:use-module (gnu packages gettext)
46 #:use-module (gnu packages glib)
47 #:use-module (gnu packages gtk)
48 #:use-module (gnu packages guile)
49 #:use-module (gnu packages haskell-xyz)
50 #:use-module (gnu packages libbsd)
51 #:use-module (gnu packages libreoffice)
52 #:use-module (gnu packages lua)
53 #:use-module (gnu packages ncurses)
54 #:use-module (gnu packages pcre)
55 #:use-module (gnu packages perl)
56 #:use-module (gnu packages pkg-config)
57 #:use-module (gnu packages python)
58 #:use-module (gnu packages python-xyz)
59 #:use-module (gnu packages qt)
60 #:use-module (gnu packages regex)
61 #:use-module (gnu packages ruby)
62 #:use-module (gnu packages terminals)
63 #:use-module (gnu packages texinfo)
64 #:use-module (gnu packages xml))
65
66 (define-public vis
67 (package
68 (name "vis")
69 (version "0.5")
70 (source (origin
71 (method url-fetch)
72 (uri (string-append "https://github.com/martanne/vis/releases"
73 "/download/v" version
74 "/vis-v" version ".tar.gz"))
75 (sha256
76 (base32
77 "0aw35n8xk7ir84ckvczc6yshj9ynishrlz0qlv4yc1afbra1gxmn"))))
78 (build-system gnu-build-system)
79 (arguments
80 `(#:test-target "test"
81 #:tests? #f ; no releases; snapshots are missing tests
82 #:phases
83 (modify-phases %standard-phases
84 (add-after 'install 'wrap-binary
85 (lambda* (#:key inputs outputs #:allow-other-keys)
86 (let* ((out (assoc-ref outputs "out"))
87 (lpeg (assoc-ref inputs "lua-lpeg"))
88 (lua-version ,(version-major+minor (package-version lua)))
89 (LUA_PATH (string-append lpeg "/share/lua/"
90 lua-version "/?.lua"))
91 (LUA_CPATH (string-append lpeg "/lib/lua/"
92 lua-version "/?.so")))
93 (wrap-program (string-append out "/bin/vis")
94 `("LUA_PATH" ":" prefix (,LUA_PATH))
95 `("LUA_CPATH" ":" prefix (,LUA_CPATH)))
96 #t))))))
97 (native-search-paths
98 (list (search-path-specification
99 (variable "VIS_PATH")
100 (files '("share/vis")))))
101 (inputs `(("lua" ,lua)
102 ("ncurses" ,ncurses)
103 ("libtermkey" ,libtermkey)
104 ("lua-lpeg" ,lua-lpeg)
105 ("tre" ,tre)))
106 (synopsis "Vim-like text editor")
107 (description
108 "Vis aims to be a modern, legacy free, simple yet efficient vim-like text
109 editor. It extends vim's modal editing with built-in support for multiple
110 cursors/selections and combines it with sam's structural regular expression
111 based command language.")
112 (home-page "https://github.com/martanne/vis")
113 (license (list license:isc ; Main distribution.
114 license:public-domain ; map.[ch]
115 license:expat)))) ; lexers and libutf.[ch]
116
117 (define-public kakoune
118 (package
119 (name "kakoune")
120 (version "2019.12.10")
121 (source
122 (origin
123 (method url-fetch)
124 (uri (string-append "https://github.com/mawww/kakoune/"
125 "releases/download/v" version "/"
126 "kakoune-" version ".tar.bz2"))
127 (sha256
128 (base32 "1y1gzax2dl7flh676k0rl1vacv10j7p5krkmb67b0afbrql8vbb6"))))
129 (build-system gnu-build-system)
130 (arguments
131 `(#:make-flags
132 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
133 #:phases
134 (modify-phases %standard-phases
135 (add-after 'unpack 'patch-source
136 (lambda _
137 ;; kakoune uses confstr with _CS_PATH to find out where to find
138 ;; a posix shell, but this doesn't work in the build
139 ;; environment. This substitution just replaces that result
140 ;; with the "sh" path.
141 (substitute* "src/shell_manager.cc"
142 (("if \\(m_shell.empty\\(\\)\\)" line)
143 (string-append "m_shell = \"" (which "sh")
144 "\";\n " line)))
145 #t))
146 (delete 'configure) ; no configure script
147 ;; kakoune requires us to be in the src/ directory to build
148 (add-before 'build 'chdir
149 (lambda _ (chdir "src") #t)))))
150 (native-inputs
151 `(("asciidoc" ,asciidoc)
152 ("pkg-config" ,pkg-config)
153 ("ruby" ,ruby)))
154 (inputs
155 `(("ncurses" ,ncurses)))
156 (synopsis "Vim-inspired code editor")
157 (description
158 "Kakoune is a code editor heavily inspired by Vim, as such most of its
159 commands are similar to Vi's ones, and it shares Vi's \"keystrokes as a text
160 editing language\" model. Kakoune has a strong focus on interactivity, most
161 commands provide immediate and incremental results, while still being
162 competitive (as in keystroke count) with Vim.")
163 (home-page "https://kakoune.org/")
164 (license license:unlicense)))
165
166 (define-public joe
167 (package
168 (name "joe")
169 (version "4.6")
170 (source
171 (origin
172 (method url-fetch)
173 (uri (string-append "https://sourceforge.net/projects/joe-editor/"
174 "files/JOE sources/joe-" version "/"
175 "joe-" version ".tar.gz"))
176 (sha256
177 (base32
178 "1pmr598xxxm9j9dl93kq4dv36zyw0q2dh6d7x07hf134y9hhlnj9"))))
179 (build-system gnu-build-system)
180 (inputs `(("ncurses" ,ncurses)))
181 (home-page "http://joe-editor.sourceforge.net/")
182 (synopsis "Console screen editor")
183 (description
184 "JOE is a powerful console screen editor with a \"mode-less\" user
185 interface similar to many user-friendly editors. JOE has some of the key
186 bindings and many of the powerful features of GNU Emacs.")
187 (license license:gpl3+)))
188
189 (define-public leafpad
190 (package
191 (name "leafpad")
192 (version "0.8.18.1")
193 (source (origin
194 (method url-fetch)
195 (uri (string-append "mirror://savannah/"
196 "leafpad/leafpad-" version ".tar.gz"))
197 (sha256
198 (base32
199 "0b0az2wvqgvam7w0ns1j8xp2llslm1rx6h7zcsy06a7j0yp257cm"))))
200 (build-system glib-or-gtk-build-system)
201 (native-inputs
202 `(("intltool" ,intltool)
203 ("pkg-config" ,pkg-config)))
204 (inputs
205 `(("gtk+" ,gtk+-2)))
206 (home-page "http://tarot.freeshell.org/leafpad/")
207 (synopsis "GTK+ based text editor")
208 (description "Leafpad is a GTK+ text editor that emphasizes simplicity. As
209 development focuses on keeping weight down to a minimum, only the most essential
210 features are implemented in the editor. Leafpad is simple to use, is easily
211 compiled, requires few libraries, and starts up quickly. ")
212 (license license:gpl2+)))
213
214 (define-public e3
215 (package
216 (name "e3")
217 (version "2.82")
218 (source (origin
219 (method url-fetch)
220 (uri (string-append "https://sites.google.com/site/e3editor/Home/"
221 "e3-" version ".tgz"))
222 (sha256
223 (base32
224 "0919kadkas020maqq37852isnzp053q2fnws2zh3mz81d1jiviak"))
225 (modules '((guix build utils)))
226
227 ;; Remove pre-built binaries.
228 (snippet '(begin
229 (delete-file-recursively "bin")
230 #t))))
231 (build-system gnu-build-system)
232 (arguments
233 `(#:tests? #f
234 #:make-flags (list (string-append "PREFIX="
235 (assoc-ref %outputs "out")))
236 #:phases (modify-phases %standard-phases
237 (delete 'configure))))
238 (native-inputs
239 `(("nasm" ,nasm)))
240 (home-page "https://sites.google.com/site/e3editor/")
241 (synopsis "Tiny text editor written in assembly")
242 (description
243 "e3 is a micro text editor with an executable code size between 3800 and
244 35000 bytes. Except for ``syntax highlighting'', the e3 binary supports all
245 of the basic functions one expects plus built in arithmetic calculations.
246 UTF-8 coding of unicode characters is supported as well. e3 can use
247 Wordstar-, EMACS-, Pico, Nedit or vi-like key bindings. e3 can be used on
248 16, 32, and 64-bit CPUs.")
249 (supported-systems '("x86_64-linux" "i686-linux"))
250 (license license:gpl2+)))
251
252 (define-public mg
253 (package
254 (name "mg")
255 (version "20180927")
256 (source (origin
257 (method git-fetch)
258 (uri (git-reference
259 (url "https://github.com/hboetes/mg")
260 (commit version)))
261 (file-name (git-file-name name version))
262 (sha256
263 (base32
264 "14vrm8lvwksf697sqks7xfd1xaqjlqjc9afjk33sksq5p27wr203"))
265 (modules '((guix build utils)))
266 (snippet '(begin
267 (substitute* "GNUmakefile"
268 (("/usr/bin/") ""))
269 #t))))
270 (build-system gnu-build-system)
271 (native-inputs
272 `(("pkg-config" ,pkg-config)))
273 (inputs
274 `(("libbsd" ,libbsd)
275 ("ncurses" ,ncurses)))
276 (arguments
277 ;; No test suite available.
278 '(#:tests? #f
279 #:make-flags (list (string-append "prefix=" %output)
280 "CC=gcc")
281 #:phases (modify-phases %standard-phases
282 (delete 'configure) ; no configure script
283 (add-before 'build 'correct-location-of-difftool
284 (lambda _
285 (substitute* "buffer.c"
286 (("/usr/bin/diff")
287 (which "diff")))
288 #t))
289 (add-before 'install 'patch-tutorial-location
290 (lambda* (#:key outputs #:allow-other-keys)
291 (substitute* "mg.1"
292 (("/usr") (assoc-ref outputs "out")))
293 #t))
294 (add-after 'install 'install-tutorial
295 (lambda* (#:key outputs #:allow-other-keys)
296 (let* ((out (assoc-ref outputs "out"))
297 (doc (string-append out "/share/doc/mg")))
298 (install-file "tutorial" doc)
299 #t))))))
300 (home-page "https://homepage.boetes.org/software/mg/")
301 (synopsis "Microscopic GNU Emacs clone")
302 (description
303 "Mg (@command{mg}) is a GNU Emacs style editor, with which it is
304 \"broadly\" compatible. This is a portable version of the mg maintained by the
305 OpenBSD team.")
306 (license license:public-domain)))
307
308 (define-public ghostwriter
309 (package
310 (name "ghostwriter")
311 (version "1.7.4")
312 (source (origin
313 (method git-fetch)
314 (uri (git-reference
315 (url "https://github.com/wereturtle/ghostwriter.git")
316 (commit (string-append "v" version))))
317 (file-name (git-file-name name version))
318 (sha256
319 (base32
320 "1pqlr08z5syqcq5p282asxwzrrm7c1w94baxyb467swh8yp3fj5m"))))
321 (build-system gnu-build-system)
322 (native-inputs
323 `(("pkg-config" ,pkg-config)
324 ("qttools" ,qttools))) ; for lrelease
325 (inputs
326 `(("hunspell" ,hunspell)
327 ("qtbase" ,qtbase)
328 ("qtmultimedia" ,qtmultimedia)
329 ("qtsvg" ,qtsvg)
330 ("qtwebkit" ,qtwebkit)))
331 (arguments
332 `(#:phases
333 (modify-phases %standard-phases
334 (replace 'configure
335 (lambda* (#:key outputs #:allow-other-keys)
336 (let ((out (assoc-ref outputs "out")))
337 (invoke "qmake" (string-append "PREFIX=" out)))))
338 (add-after 'configure 'create-translations
339 (lambda _
340 ;; `lrelease` will not overwrite, so delete existing .qm files
341 (for-each delete-file (find-files "translations" ".*\\.qm"))
342 (apply invoke "lrelease" (find-files "translations" ".*\\.ts"))))
343 ;; Ensure that icons are found at runtime.
344 (add-after 'install 'wrap-executable
345 (lambda* (#:key inputs outputs #:allow-other-keys)
346 (let ((out (assoc-ref outputs "out")))
347 (wrap-program (string-append out "/bin/ghostwriter")
348 `("QT_PLUGIN_PATH" ":" prefix
349 ,(map (lambda (label)
350 (string-append (assoc-ref inputs label)
351 "/lib/qt5/plugins/"))
352 '("qtsvg" "qtmultimedia"))))))))))
353 (home-page "https://wereturtle.github.io/ghostwriter/")
354 (synopsis "Write without distractions")
355 (description
356 "@code{ghostwriter} provides a relaxing, distraction-free writing
357 environment with Markdown markup.")
358 (license license:gpl3+))) ; icons/* under CC-BY-SA3
359
360 (define-public manuskript
361 (package
362 (name "manuskript")
363 (version "0.10.0")
364 (source
365 (origin
366 (method git-fetch)
367 (uri (git-reference
368 (url "https://github.com/olivierkes/manuskript.git")
369 (commit version)))
370 (file-name (git-file-name name version))
371 (sha256
372 (base32 "0q413vym7hzjpyg3krj5y63hwpncdifjkyswqmr76zg5yqnklnh3"))))
373 (build-system python-build-system)
374 (arguments
375 `(#:tests? #f ;no test
376 #:phases
377 (modify-phases %standard-phases
378 (delete 'configure)
379 (delete 'build)
380 (replace 'install
381 (lambda* (#:key outputs #:allow-other-keys)
382 (let* ((out (assoc-ref outputs "out"))
383 (share (string-append out "/share/manuskript")))
384 ;; Install data.
385 (mkdir-p share)
386 (for-each
387 (lambda (d)
388 (let ((destination (string-append share "/" d)))
389 (mkdir-p destination)
390 (copy-recursively d destination)))
391 '("bin" "i18n" "icons" "libs" "manuskript" "resources"))
392 ;; Install documentation.
393 (let ((doc (string-append out
394 "/doc/manuskript-" ,version
395 "/sample-projects")))
396 (mkdir-p doc)
397 (copy-recursively "sample-projects" doc))
398 ;; Wrap executable in "$out/share/manuskript/bin" and
399 ;; link to it from "$out/bin".
400 (let ((bin (string-append out "/bin"))
401 (executable (string-append share "/bin/manuskript")))
402 (wrap-program executable
403 (list "PYTHONPATH" 'prefix (list (getenv "PYTHONPATH"))))
404 (mkdir-p bin)
405 (with-directory-excursion bin
406 (symlink (string-append share "/bin/manuskript")
407 "manuskript")))
408 ;; Install icons and create .desktop file.
409 (let ((apps (string-append out "/share/applications"))
410 (icons-dir (string-append out "/share/pixmaps")))
411 (install-file "icons/Manuskript/manuskript.svg" icons-dir)
412 (mkdir-p apps)
413 (with-output-to-file (string-append apps "/manuskript.desktop")
414 (lambda _
415 (format #t
416 "[Desktop Entry]~@
417 Name=Manuskript~@
418 MimeType=application/x-manuskript-book;~@
419 Exec=~a/bin/manuskript %f~@
420 Comment=Tool for writers~@
421 Comment[es]=Herramienta para escritores/as~@
422 Keywords=manuskript;office;write;edit;novel;text;msk~@
423 Terminal=false~@
424 Type=Application~@
425 Icon=manuskript~@
426 Categories=Office;WordProcessor;~%"
427 out))))
428 #t))))))
429 (inputs
430 `(("ghc-pandoc" ,ghc-pandoc)
431 ("python-lxml" ,python-lxml)
432 ("python-markdown" ,python-markdown)
433 ("python-pyqt" ,python-pyqt)
434 ("qtsvg" ,qtsvg)))
435 (home-page "http://www.theologeek.ch/manuskript/")
436 (synopsis "Tool for writers")
437 (description "Manuskript provides a rich environment to help
438 writers create their first draft and then further refine and edit
439 their masterpiece. With Manuskript you can:
440
441 @itemize
442 @item Grow your premise from one sentence, to a paragraph, to a full
443 summary,
444 @item Create characters,
445 @item Conceive plots,
446 @item Construct outlines (Outline mode and/or Index cards),
447 @item Write with focus (Distraction free mode),
448 @item Build worlds,
449 @item Track items,
450 @item Edit and re-organize chapters and scenes,
451 @item View Story line,
452 @item Compose with fiction or non-fiction templates and writing modes,
453 @item Import and export document formats such as HTML, ePub,
454 OpenDocument, DocX, and more.
455 @end itemize
456
457 Additionally Manuskript can help in many more ways with a spell
458 checker, markdown highlighter, frequency analyzer, and automatic save
459 in plain text file format.")
460 (license license:gpl3+)))
461
462 (define-public editorconfig-core-c
463 (package
464 (name "editorconfig-core-c")
465 (version "0.12.3")
466 (source
467 (origin
468 (method git-fetch)
469 (uri (git-reference
470 (url "https://github.com/editorconfig/editorconfig-core-c.git")
471 (commit (string-append "v" version))))
472 (file-name (git-file-name name version))
473 (sha256
474 (base32
475 "0jkc69r4jwn4rih6h6cqvgljjc3ff49cxj8286mi515aczr48cm1"))))
476 (build-system cmake-build-system)
477 (arguments
478 '(#:phases
479 (modify-phases %standard-phases
480 (add-after 'unpack 'insert-tests
481 (lambda* (#:key inputs #:allow-other-keys)
482 (let ((tests (assoc-ref inputs "tests")))
483 (copy-recursively tests "tests"))
484 #t)))))
485 (native-inputs
486 `(("tests" ,(origin
487 (method git-fetch)
488 (uri (git-reference
489 (url "https://github.com/editorconfig/editorconfig-core-test")
490 (commit "6ea1d8ece62cac9cf72c79dce4879b046abe1fe7"))) ; matches version
491 (file-name (git-file-name "editorconfig-core-test" version))
492 (sha256
493 (base32
494 "1sf6910idnd4bgzbj8w8f9ldsbkaqa0lh6syymwy3hfqda63acj7"))))))
495 (inputs
496 `(("pcre2" ,pcre2)))
497 (home-page "https://editorconfig.org/")
498 (synopsis "EditorConfig core library written in C")
499 (description "EditorConfig makes it easy to maintain the correct coding
500 style when switching between different text editors and between different
501 projects. The EditorConfig project maintains a file format and plugins for
502 various text editors which allow this file format to be read and used by those
503 editors.")
504 (license license:bsd-2)))
505
506 (define-public texmacs
507 (package
508 (name "texmacs")
509 (version "1.99.11")
510 (source
511 (origin
512 (method url-fetch)
513 (uri (string-append "https://www.texmacs.org/Download/ftp/tmftp/"
514 "source/TeXmacs-" version "-src.tar.gz"))
515 (sha256
516 (base32 "12bp0f34izzqimz49lfpgf4lyz3h45s9xbmk8v6zsawdjki76alg"))
517 (modules '((guix build utils)))
518 (snippet
519 '(begin
520 (delete-file-recursively "3rdparty")
521 #t))))
522 (build-system gnu-build-system)
523 (native-inputs
524 `(("pkg-config" ,pkg-config)))
525 (inputs
526 `(("freetype" ,freetype)
527 ("guile" ,guile-1.8)
528 ("perl" ,perl)
529 ("python" ,python-wrapper)
530 ("qt" ,qt-4)))
531 (arguments
532 `(#:tests? #f ; no check target
533 #:phases
534 (modify-phases %standard-phases
535 (add-before 'configure 'gzip-flags
536 (lambda _
537 (substitute* "Makefile.in"
538 (("^GZIP = gzip -f") "GZIP = gzip -f -n")))))))
539 (synopsis "Editing platform with special features for scientists")
540 (description
541 "GNU TeXmacs is a text editing platform which is specialized for
542 scientists. It is ideal for editing structured documents with different
543 types of content. It has robust support for mathematical formulas and plots.
544 It can also act as an interface to external mathematical programs such as R
545 and Octave. TeXmacs is completely extensible via Guile.")
546 (license license:gpl3+)
547 (home-page "https://www.texmacs.org/tmweb/home/welcome.en.html")))
548
549 (define-public scintilla
550 (package
551 (name "scintilla")
552 (version "4.2.2")
553 (source (origin
554 (method url-fetch)
555 (uri (let ((v (apply string-append (string-split version #\.))))
556 (string-append
557 "https://www.scintilla.org/scintilla" v ".tgz")))
558 (sha256
559 (base32
560 "01gq31ggvasw4sy9xs544h7v1dmxrlxs5bzxpasqb9yi3ps3nl0f"))))
561 (build-system gnu-build-system)
562 (arguments
563 `(#:make-flags (list "GTK3=1" "CC=gcc" "-Cgtk")
564 #:tests? #f ;require un-packaged Pyside
565 #:phases
566 (modify-phases %standard-phases
567 (delete 'configure) ;no configure script
568 (add-after 'unpack 'build-shared-library
569 (lambda _
570 (substitute* "gtk/makefile"
571 (("scintilla\\.a") "libscintilla.so")
572 (("\\$\\(AR\\) \\$\\(ARFLAGS\\) \\$@ \\$\\^")
573 "$(CC) -shared $^ -o $@")
574 (("\\$\\(RANLIB\\) \\$@") ""))
575 #t))
576 (replace 'install
577 (lambda* (#:key outputs #:allow-other-keys)
578 (let* ((out (assoc-ref outputs "out"))
579 (lib (string-append out "/lib"))
580 (include (string-append out "/include")))
581 (install-file "bin/libscintilla.so" lib)
582 (for-each (lambda (f) (install-file f include))
583 (find-files "include/" "."))
584 #t))))))
585 (native-inputs
586 `(("pkg-config" ,pkg-config)
587 ("python" ,python-wrapper)))
588 (inputs
589 `(("gtk+" ,gtk+)))
590 (home-page "https://www.scintilla.org/")
591 (synopsis "Code editor for GTK+")
592 (description "Scintilla is a source code editing component for
593 GTK+. It has the usual features found in text editing components, as
594 well as some that are especially useful for editing and debugging
595 source code; these include support for syntax styling, error
596 indicators, code completion and call tips. Styling choices are more
597 open than with many editors: Scintilla lets you use proportional
598 fonts, bold and italics, multiple foreground and background colours,
599 and multiple fonts.")
600 (license license:hpnd)))
601
602 (define-public geany
603 (package
604 (name "geany")
605 (version "1.36")
606 (source (origin
607 (method url-fetch)
608 (uri (string-append "https://download.geany.org/"
609 "geany-" version ".tar.bz2"))
610 (sha256
611 (base32
612 "0gnm17cr4rf3pmkf0axz4a0fxwnvp55ji0q0lzy88yqbshyxv14i"))
613 (modules '((guix build utils)))
614 (snippet '(begin
615 (delete-file-recursively "scintilla")
616 #t))))
617 (build-system gnu-build-system)
618 (native-inputs
619 `(("autoconf" ,autoconf)
620 ("automake" ,automake)
621 ("doxygen" ,doxygen)
622 ("glib" ,glib "bin")
623 ("intltool" ,intltool)
624 ("libtool" ,libtool)
625 ("pkg-config" ,pkg-config)
626 ("python-docutils" ,python-docutils))) ;for rst2html
627 (inputs
628 `(("gtk+" ,gtk+)
629 ("scintilla" ,scintilla)))
630 (arguments
631 `(#:phases
632 (modify-phases %standard-phases
633 (add-after 'unpack 'use-scintilla-shared-library
634 (lambda* (#:key inputs #:allow-other-keys)
635 (substitute* "configure.ac"
636 (("scintilla/Makefile") "")
637 (("scintilla/include/Makefile") ""))
638 (substitute* "Makefile.am"
639 (("scintilla ") ""))
640 (substitute* "src/Makefile.am"
641 (("\\$\\(top_builddir\\)/scintilla/libscintilla.la") "")
642 (("geany_LDFLAGS =" all) (string-append all " -lscintilla")))
643 (substitute* "doc/Makefile.am"
644 (("\\$\\(INSTALL_DATA\\) \\$\\(top_srcdir\\)/scintilla/License.txt \\$\\(DOCDIR\\)/ScintillaLicense.txt") ""))
645 (substitute* "tests/Makefile.am"
646 (("AM_LDFLAGS =" all) (string-append all " -lscintilla")))
647 (for-each delete-file (list "autogen.sh" "configure" "Makefile.in"))
648 #t)))))
649 (home-page "https://www.geany.org")
650 (synopsis "Fast and lightweight IDE")
651 (description "Geany is a small and fast Integrated Development
652 Environment (IDE) that only has a few dependencies on other packages and is as
653 independent as possible from special desktop environments like KDE or GNOME.
654
655 The basic features of Geany are:
656 @itemize
657 @item syntax highlighting
658 @item code completion
659 @item auto completion of often constructed constructs like if, for and while
660 @item auto completion of XML and HTML tags
661 @item call tips
662 @item folding
663 @item many supported filetypes like C, Java, PHP, HTML, Python, Perl, Pascal
664 @item symbol lists
665 @item embedded terminal emulation
666 @item extensibility through plugins
667 @end itemize")
668 (license license:gpl2+)))
669
670 (define-public fe
671 (package
672 (name "fe")
673 ;; Stable release is 1.8. However, this development version
674 ;; introduces support for UTF-8.
675 (version "2.0")
676 (source (origin
677 (method url-fetch)
678 (uri (string-append "http://www.moria.de/~michael/fe/"
679 "fe-" version ".tar.gz"))
680 (sha256
681 (base32
682 "1hwws7si1752z6hp61zxznvgsb6846lp8zl1hn5ddhsbafwalwb9"))))
683 (build-system gnu-build-system)
684 (arguments
685 `(#:tests? #f ;no test
686 ;; Sendmail is only used to send a crash log. Disable the
687 ;; feature since it is (1) undocumented (2) not very useful.
688 #:configure-flags (list "--disable-sendmail")
689 #:phases
690 (modify-phases %standard-phases
691 (add-after 'install 'install-doc
692 (lambda* (#:key outputs #:allow-other-keys)
693 (let* ((out (assoc-ref outputs "out"))
694 (doc (string-append out "/share/doc/" ,name "-" ,version)))
695 (for-each (lambda (f) (install-file f doc))
696 '("fe.doc" "fe.html" "fe.ps" "feref.ps" "README"))
697 #t))))))
698 (native-inputs
699 `(("gettext" ,gettext-minimal)))
700 (inputs
701 `(("ncurses" ,ncurses)))
702 (home-page "http://www.moria.de/~michael/fe/")
703 (synopsis "Small folding editor")
704 (description "Fe is a small folding editor. It allows to fold
705 arbitrary text regions; it is not bound to syntactic units.
706
707 Fe has no configuration or extension language and requires no setup.
708 Its user interface is emacs-like and it has menus for the very most
709 important functions to help beginners. Further there is a reference
710 card. It offers:
711
712 @itemize
713 @item Regions and Emacs-like kill ring
714 @item Incremental search
715 @item Keyboard macros
716 @item Editing binary files
717 @item Multiple windows and views
718 @item Compose function for Latin 1 characters
719 @end itemize")
720 (license license:gpl2+)))
721
722 (define-public ne
723 (package
724 (name "ne")
725 (version "3.2.1")
726 (source (origin
727 (method git-fetch)
728 (uri (git-reference
729 (url "https://github.com/vigna/ne.git")
730 (commit version)))
731 (file-name (git-file-name name version))
732 (sha256
733 (base32
734 "0h6d08cnwrk96ss83i9bragwwanph6x54sm3ak1z81146dsqsiif"))))
735 (build-system gnu-build-system)
736 (native-inputs
737 `(("perl" ,perl)
738 ("texinfo" ,texinfo)))
739 (inputs
740 `(("ncurses" ,ncurses)))
741 (arguments
742 `(#:tests? #f
743 #:make-flags
744 (list "CC=gcc"
745 (string-append "PREFIX=" (assoc-ref %outputs "out"))
746 (string-append "LDFLAGS=-L" (assoc-ref %build-inputs "ncurses")
747 "/lib"))
748 #:phases
749 (modify-phases %standard-phases
750 (replace 'configure
751 (lambda _
752 (substitute* "src/makefile"
753 (("-lcurses") "-lncurses"))
754 #t)))))
755 (home-page "http://ne.di.unimi.it/")
756 (synopsis "Text editor with menu bar")
757 (description "This package provides a modeless text editor with menu bar.
758 It supports syntax highlighting, regular expressions, configurable menus,
759 keybindings, autocomplete and unlimited undo. It can pipe a marked block
760 of text through any command line filter. It can also open very large binary
761 files. It was originally developed on the Amiga 3000T.")
762 (license license:gpl3+)))