/*** Set top-left visible corner ***/ void set_top_line(Project p, ULONG top, ULONG left) { LINE *ln; LONG nb = top-p->top_line; if(nb < 0) for(ln=p->show; nb++; ln=ln->prev); else for(ln=p->show; nb--; ln=ln->next); p->show = ln; p->top_line = top; p->left_pos = left; p->xcurs = (p->nbrc-p->left_pos) * XSIZE + gui.left; redraw_content(p, ln, gui.topcurs, gui.nbline); prop_adj( p ); }
LVAL iview_spin_redraw_content(V) { IVIEW_WINDOW w; LVAL object; object = xlgaobject(); w = (IVIEW_WINDOW) GETIVIEWADDRESS(object); xllastarg(); if (! IVIEW_WINDOW_NULL(w)) redraw_content(w, object); return(NIL); }
/*** Refresh display, according to new window size ***/ void new_size(UBYTE Flags) { inv_curs(edit, FALSE); adjust_win(Wnd,NbProject>1); /* Adjust internal variables */ SetABPenDrMd(RP, pen.fg, pen.bg, JAM2); clear_brcorner(); prop_adj(edit); edit->left_pos = curs_visible(edit, edit->top_line); edit->xcurs = (edit->nbrc - edit->left_pos)*XSIZE + gui.left; if(Flags & EDIT_GUI) reshape_panel(edit); if(Flags & EDIT_AREA) redraw_content(edit,edit->show,gui.topcurs,gui.nbline); inv_curs(edit,TRUE); }