- (unless (and (prog1
- (search-backward
- "\\fontencoding{LGR}\\selectfont{}" nil t)
- (goto-char pos))
- (eq pos (match-end 0)))
- (insert "\\fontencoding{LGR}\\selectfont{}")
- )
- (forward-char)
- (setq font-encoding 'LGR))
- (skip-chars-forward "\u0374-\u03F3")
- (unless (eq font-encoding 'T1)
- (unless (looking-at
- "\\\\fontencoding{T1}\\\\selectfont{}")
- (insert "\\fontencoding{T1}\\selectfont{}")
- )
- (setq font-encoding 'T1))
+ ;; (unless (and (prog1
+ ;; (search-backward
+ ;; "\\fontencoding{LGR}\\selectfont{}" nil t)
+ ;; (goto-char pos))
+ ;; (eq pos (match-end 0)))
+ ;; (insert "\\fontencoding{LGR}\\selectfont{}")
+ ;; )
+ (if (search-backward "\\GreekScript{"
+ (- pos (eval-when-compile
+ (length "\\GreekScript{")))
+ t)
+ (search-forward "}" nil t)
+ (insert "\\GreekScript{")
+ (forward-char)
+ (skip-chars-forward "\u0374-\u03F3 ")
+ (insert "}"))
+ ;; (setq font-encoding 'LGR)
+ )
+ ;; (unless (eq font-encoding 'T1)
+ ;; (unless (looking-at
+ ;; "\\\\fontencoding{T1}\\\\selectfont{}")
+ ;; (insert "\\fontencoding{T1}\\selectfont{}")
+ ;; )
+ ;; (setq font-encoding 'T1))