|
105 | 105 | (let ((link-start (point)))
|
106 | 106 | (insert (car record))
|
107 | 107 | (let ((button (make-text-button link-start (point) :type 'haskell-show-toggle-button)))
|
108 |
| - (put-text-property link-start (point) 'face 'font-lock-type-face) |
| 108 | + (put-text-property link-start (point) 'font-lock-face 'font-lock-type-face) |
109 | 109 | (button-put button 'overlay overlay)))
|
110 | 110 | (insert " {\n")
|
111 | 111 | (let ((curly-start (1- (point)))
|
|
116 | 116 | (if (and (> i 0) (< show-len 80)) 0 column)
|
117 | 117 | (car field)))
|
118 | 118 | (insert " = ")
|
119 |
| - (put-text-property (- (point) 3) (point) 'face |
| 119 | + (put-text-property (- (point) 3) (point) 'font-lock-face |
120 | 120 | 'font-lock-constant-face)
|
121 | 121 | (haskell-show-insert-pretty
|
122 | 122 | (if (< show-len 80)
|
|
135 | 135 | (insert (if parens ")" "")))))
|
136 | 136 | ('num (let ((num-start (point)))
|
137 | 137 | (insert (format "%d" (cdr tree)))
|
138 |
| - (put-text-property num-start (point) 'face 'font-lock-constant-face))) |
| 138 | + (put-text-property num-start (point) 'font-lock-face 'font-lock-constant-face))) |
139 | 139 | ('string (let ((str-start (point)))
|
140 | 140 | (insert "\"")
|
141 | 141 | (if (< (+ column (length (cdr tree))) 60)
|
142 | 142 | (progn
|
143 | 143 | (insert (format "%s" (cdr tree)))
|
144 |
| - (put-text-property (+ 1 str-start) (point) 'face 'font-lock-string-face)) |
| 144 | + (put-text-property (+ 1 str-start) (point) 'font-lock-face 'font-lock-string-face)) |
145 | 145 | (progn
|
146 | 146 | (insert "…")
|
147 | 147 | (insert (format "%s" (cdr tree)))
|
148 | 148 | (let ((overlay (make-overlay (+ 2 str-start) (point) nil t)))
|
149 | 149 | (overlay-put overlay 'invisible t)
|
150 |
| - (put-text-property (+ 2 str-start) (point) 'face 'font-lock-string-face) |
| 150 | + (put-text-property (+ 2 str-start) (point) 'font-lock-face 'font-lock-string-face) |
151 | 151 | (let ((button (make-text-button (+ 1 str-start) (+ 2 str-start)
|
152 | 152 | :type 'haskell-show-toggle-button)))
|
153 | 153 | (put-text-property (+ 1 str-start) (+ 2 str-start)
|
154 |
| - 'face 'font-lock-keyword-face) |
| 154 | + 'font-lock-face 'font-lock-keyword-face) |
155 | 155 | (button-put button 'overlay (list overlay))
|
156 | 156 | (button-put button 'hide-on-click t)))))
|
157 | 157 | (insert "\"")))
|
158 | 158 | ('data (let ((data (cdr tree)))
|
159 | 159 | (insert (if parens "(" ""))
|
160 | 160 | (let ((cons-start (point)))
|
161 | 161 | (insert (car data))
|
162 |
| - (put-text-property cons-start (point) 'face 'font-lock-type-face)) |
| 162 | + (put-text-property cons-start (point) 'font-lock-face 'font-lock-type-face)) |
163 | 163 | (unless (null (cdr data))
|
164 | 164 | (progn (insert " ")
|
165 | 165 | (haskell-show-mapcar/i
|
|
171 | 171 | (insert (if parens ")" ""))))
|
172 | 172 | ('char (progn (insert "'")
|
173 | 173 | (insert (char-to-string (cdr tree)))
|
174 |
| - (put-text-property (- (point) 1) (point) 'face 'font-lock-string-face) |
| 174 | + (put-text-property (- (point) 1) (point) 'font-lock-face 'font-lock-string-face) |
175 | 175 | (insert "'")))
|
176 | 176 | ('arbitrary (let ((start (point)))
|
177 | 177 | (insert (cdr tree))
|
178 |
| - (put-text-property start (point) 'face 'font-lock-comment-face))) |
| 178 | + (put-text-property start (point) 'font-lock-face 'font-lock-comment-face))) |
179 | 179 | (otherwise (error "Unsupported node type: %S" tree))))
|
180 | 180 |
|
181 | 181 | (define-button-type 'haskell-show-toggle-button
|
|
0 commit comments