| 1 |
(* M2ColorString.def provides procedures for obtaining GCC color strings. |
| 2 |
|
| 3 |
Copyright (C) 2019-2025 Free Software Foundation, Inc. |
| 4 |
Contributed by Gaius Mulley <[email protected]>. |
| 5 |
|
| 6 |
This file is part of GNU Modula-2. |
| 7 |
|
| 8 |
GNU Modula-2 is free software; you can redistribute it and/or modify |
| 9 |
it under the terms of the GNU General Public License as published by |
| 10 |
the Free Software Foundation; either version 3, or (at your option) |
| 11 |
any later version. |
| 12 |
|
| 13 |
GNU Modula-2 is distributed in the hope that it will be useful, but |
| 14 |
WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 16 |
General Public License for more details. |
| 17 |
|
| 18 |
You should have received a copy of the GNU General Public License |
| 19 |
along with GNU Modula-2; see the file COPYING3. If not see |
| 20 |
<http://www.gnu.org/licenses/>. *) |
| 21 |
|
| 22 |
DEFINITION MODULE M2ColorString ; (*!m2pim+gm2*) |
| 23 |
|
| 24 |
(* |
| 25 |
Title : M2ColorString |
| 26 |
Author : Gaius Mulley |
| 27 |
System : GNU Modula-2 |
| 28 |
Date : Sat Apr 13 19:21:03 2019 |
| 29 |
Revision : $Version$ |
| 30 |
Description: provides procedures for obtaining GCC color strings. |
| 31 |
*) |
| 32 |
|
| 33 |
FROM DynamicStrings IMPORT String ; |
| 34 |
|
| 35 |
|
| 36 |
(* |
| 37 |
SetEnableColor - sets the global variable to, b, and returns |
| 38 |
the previous value. |
| 39 |
*) |
| 40 |
|
| 41 |
PROCEDURE SetEnableColor (b: BOOLEAN) : BOOLEAN ; |
| 42 |
|
| 43 |
|
| 44 |
(* |
| 45 |
quoteOpen - adds an open quote to string, s. |
| 46 |
*) |
| 47 |
|
| 48 |
PROCEDURE quoteOpen (s: String) : String ; |
| 49 |
|
| 50 |
|
| 51 |
(* |
| 52 |
quoteClose - adds a close quote to string, s. |
| 53 |
*) |
| 54 |
|
| 55 |
PROCEDURE quoteClose (s: String) : String ; |
| 56 |
|
| 57 |
|
| 58 |
(* |
| 59 |
endColor - stops using color. |
| 60 |
*) |
| 61 |
|
| 62 |
PROCEDURE endColor (s: String) : String ; |
| 63 |
|
| 64 |
|
| 65 |
(* |
| 66 |
quoteColor - adds quote color to string, s. |
| 67 |
*) |
| 68 |
|
| 69 |
PROCEDURE quoteColor (s: String) : String ; |
| 70 |
|
| 71 |
|
| 72 |
(* |
| 73 |
errorColor - adds error color to string, s. |
| 74 |
*) |
| 75 |
|
| 76 |
PROCEDURE errorColor (s: String) : String ; |
| 77 |
|
| 78 |
|
| 79 |
(* |
| 80 |
warningColor - adds warning color to string, s. |
| 81 |
*) |
| 82 |
|
| 83 |
PROCEDURE warningColor (s: String) : String ; |
| 84 |
|
| 85 |
|
| 86 |
(* |
| 87 |
noteColor - adds note color to string, s. |
| 88 |
*) |
| 89 |
|
| 90 |
PROCEDURE noteColor (s: String) : String ; |
| 91 |
|
| 92 |
|
| 93 |
(* |
| 94 |
locusColor - adds locus color to string, s. |
| 95 |
*) |
| 96 |
|
| 97 |
PROCEDURE locusColor (s: String) : String ; |
| 98 |
|
| 99 |
|
| 100 |
(* |
| 101 |
insertColor - adds fixit-insert color to string, s. |
| 102 |
*) |
| 103 |
|
| 104 |
PROCEDURE insertColor (s: String) : String ; |
| 105 |
|
| 106 |
|
| 107 |
(* |
| 108 |
deleteColor - adds fixit-insert color to string, s. |
| 109 |
*) |
| 110 |
|
| 111 |
PROCEDURE deleteColor (s: String) : String ; |
| 112 |
|
| 113 |
|
| 114 |
(* |
| 115 |
filenameColor - adds filename color to string, s. |
| 116 |
*) |
| 117 |
|
| 118 |
PROCEDURE filenameColor (s: String) : String ; |
| 119 |
|
| 120 |
|
| 121 |
(* |
| 122 |
typeColor - adds type color to string, s. |
| 123 |
*) |
| 124 |
|
| 125 |
PROCEDURE typeColor (s: String) : String ; |
| 126 |
|
| 127 |
|
| 128 |
(* |
| 129 |
range1Color - adds type color to string, s. |
| 130 |
*) |
| 131 |
|
| 132 |
PROCEDURE range1Color (s: String) : String ; |
| 133 |
|
| 134 |
|
| 135 |
(* |
| 136 |
range2Color - adds type color to string, s. |
| 137 |
*) |
| 138 |
|
| 139 |
PROCEDURE range2Color (s: String) : String ; |
| 140 |
|
| 141 |
|
| 142 |
END M2ColorString. |