]> Sergey Matveev's repositories - stargrave-blog.git/commit
Патч на заголовок Lynx в tmux
authorSergey Matveev <stargrave@stargrave.org>
Mon, 25 Nov 2019 07:53:33 +0000 (10:53 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Mon, 25 Nov 2019 07:53:33 +0000 (10:53 +0300)
commita24b31d9e133ad261dadfccf115f28ca5af77ed5
tree4b825dc642cb6eb9a060e54bf8d69288fbee4904
parent14795f54bef11fb2042edd5ec423fbd530d21a88
Патч на заголовок Lynx в tmux

В продолжении 5921d398e70fd8227bbeaae070604ffef7357d55 осилил-таки
перерисовку окна (без необходимости нажимать Ctrl-L) добавлением одной
строки. Теперь куда меньше геморроя!

--- src/GridText.c.orig 2017-07-04 20:27:07.000000000 +0300
+++ src/GridText.c 2019-11-25 10:49:48.406034000 +0300
@@ -1658,6 +1658,17 @@
     if (!text)
  return;

+    /*
+     * Load the title field.  -FM
+     */
+    StrAllocCopy(title,
+  (HTAnchor_title(text->node_anchor) ?
+   HTAnchor_title(text->node_anchor) : " ")); /* "" -> " " */
+    LYReduceBlanks(title);
+    printf("\033]2;%s\a\n", title);
+    lynx_force_repaint();
+    LYrefresh();
+
     lynx_start_title_color();
 #ifdef USE_COLOR_STYLE
 /* turn the TITLE style on */
@@ -1667,14 +1678,6 @@
  LynxChangeStyle(s_title, ABS_ON);
     }
 #endif /* USE_COLOR_STYLE */
-
-    /*
-     * Load the title field.  -FM
-     */
-    StrAllocCopy(title,
-  (HTAnchor_title(text->node_anchor) ?
-   HTAnchor_title(text->node_anchor) : " ")); /* "" -> " " */
-    LYReduceBlanks(title);

     /*
      * Generate the page indicator (percent) string.