Skip to content
Snippets Groups Projects
Commit 54a8d81f authored by deuce's avatar deuce
Browse files

Setup the shadow palette and fonts in offline scrollback.

Fixes https://sourceforge.net/p/syncterm/tickets/10/ as well as various color
corruption issues in offline scrollback that date back to the sixel "stuff"
parent 744d3615
Branches
Tags
No related merge requests found
......@@ -259,7 +259,7 @@ void viewofflinescroll(void)
if(scrollback_buf==NULL)
return;
uifcbail();
gettextinfo(&txtinfo);
gettextinfo(&txtinfo);
textmode(scrollback_mode);
switch(ciolib_to_screen(scrollback_mode)) {
......@@ -275,11 +275,21 @@ void viewofflinescroll(void)
setfont(36,TRUE,1);
break;
}
/* Set up a shadow palette */
if (cio_api.options & CONIO_OPT_EXTENDED_PALETTE) {
for (i=0; i < sizeof(dac_default)/sizeof(struct dac_colors); i++)
setpalette(i + 16, dac_default[i].red << 8 | dac_default[i].red, dac_default[i].green << 8 | dac_default[i].green, dac_default[i].blue << 8 | dac_default[i].blue);
}
setfont(0, FALSE, 1);
setfont(0, FALSE, 2);
setfont(0, FALSE, 3);
setfont(0, FALSE, 4);
drawwin();
set_modepalette(palettes[COLOUR_PALETTE]);
top=scrollback_lines;
gotoxy(1,1);
textattr(uifc.hclr|(uifc.bclr<<4)|BLINK);
gettextinfo(&sbtxtinfo);
gettextinfo(&sbtxtinfo);
for(i=0;!i && !quitting;) {
if(top<1)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment