comparison src/redisplay-tty.c @ 265:8efd647ea9ca r20-5b31

Import from CVS: tag r20-5b31
author cvs
date Mon, 13 Aug 2007 10:25:37 +0200
parents 677f6a0ee643
children c5d627a313b1
comparison
equal deleted inserted replaced
264:682d2a9d41a5 265:8efd647ea9ca
181 #endif 181 #endif
182 tty_output_end (struct device *d) 182 tty_output_end (struct device *d)
183 { 183 {
184 struct console *c = XCONSOLE (DEVICE_CONSOLE (d)); 184 struct console *c = XCONSOLE (DEVICE_CONSOLE (d));
185 185
186 CONSOLE_TTY_CURSOR_X (c) = CONSOLE_TTY_FINAL_CURSOR_X (c);
187 CONSOLE_TTY_CURSOR_Y (c) = CONSOLE_TTY_FINAL_CURSOR_Y (c);
186 FORCE_CURSOR_UPDATE (c); 188 FORCE_CURSOR_UPDATE (c);
187 Lstream_flush (XLSTREAM (CONSOLE_TTY_DATA (c)->outstream)); 189 Lstream_flush (XLSTREAM (CONSOLE_TTY_DATA (c)->outstream));
190 }
191
192 static void
193 tty_set_final_cursor_coords (struct frame *f, int y, int x)
194 {
195 struct console *c = XCONSOLE (FRAME_CONSOLE (f));
196
197 CONSOLE_TTY_FINAL_CURSOR_X (c) = x;
198 CONSOLE_TTY_FINAL_CURSOR_Y (c) = y;
188 } 199 }
189 200
190 /***************************************************************************** 201 /*****************************************************************************
191 tty_output_display_block 202 tty_output_display_block
192 203
545 556
546 tty_turn_on_frame_face (f, Vdefault_face); 557 tty_turn_on_frame_face (f, Vdefault_face);
547 if (TTY_SE (c).clr_frame) 558 if (TTY_SE (c).clr_frame)
548 { 559 {
549 OUTPUT1 (c, TTY_SE (c).clr_frame); 560 OUTPUT1 (c, TTY_SE (c).clr_frame);
561 CONSOLE_TTY_REAL_CURSOR_X (c) = 0;
562 CONSOLE_TTY_REAL_CURSOR_Y (c) = 0;
550 #ifdef NOT_SURE 563 #ifdef NOT_SURE
551 FRAME_CURSOR_X (f) = 0; 564 FRAME_CURSOR_X (f) = 0;
552 FRAME_CURSOR_Y (f) = 0; 565 FRAME_CURSOR_Y (f) = 0;
553 #endif 566 #endif
554 } 567 }
954 /* Clear the bottom line of the frame. */ 967 /* Clear the bottom line of the frame. */
955 tty_clear_region (FRAME_SELECTED_WINDOW (f), DEFAULT_INDEX, 0, 968 tty_clear_region (FRAME_SELECTED_WINDOW (f), DEFAULT_INDEX, 0,
956 f->height, f->width, 1); 969 f->height, f->width, 1);
957 970
958 /* And then stick the cursor there. */ 971 /* And then stick the cursor there. */
959 cmgoto (f, f->height, 0); 972 tty_set_final_cursor_coords (f, f->height, 0);
960 tty_output_end (XDEVICE (dev)); 973 tty_output_end (XDEVICE (dev));
961 } 974 }
962 } 975 }
963 } 976 }
964 977
1541 CONSOLE_HAS_METHOD (tty, clear_frame); 1554 CONSOLE_HAS_METHOD (tty, clear_frame);
1542 CONSOLE_HAS_METHOD (tty, output_begin); 1555 CONSOLE_HAS_METHOD (tty, output_begin);
1543 CONSOLE_HAS_METHOD (tty, output_end); 1556 CONSOLE_HAS_METHOD (tty, output_end);
1544 CONSOLE_HAS_METHOD (tty, flash); 1557 CONSOLE_HAS_METHOD (tty, flash);
1545 CONSOLE_HAS_METHOD (tty, ring_bell); 1558 CONSOLE_HAS_METHOD (tty, ring_bell);
1546 } 1559 CONSOLE_HAS_METHOD (tty, set_final_cursor_coords);
1560 }