Ejemplo n.º 1
0
/*
 * scrollHelp - refresh the displayed help after a scrolling operation
 */
static int scrollHelp( SAREA *use, int lastline, bool changecurr )
{
    int         useline;
    int         scroll;
    int         start;
    int         end;

    scroll = currLine - lastline;
    vscroll_fields( &helpTab, *use, scroll );
    vvscroll( &helpScreen, *use, scroll );
    currentAttr = AT( ATTR_NORMAL );
    if( abs(scroll) >= use->height ) {
        start = currLine;
        end = start + use->height;
    } else if( scroll < 0 ) {
        start = currLine;
        end = start - scroll;
    } else {
        start = currLine + use->height - scroll;
        end = start + scroll;
    }
    seek_line( start );
    for( ;; ++start ) {
        save_line( start, HelpTell( helpFileHdl ) );
        if( !mygetline() || strncmp( helpInBuf, "::::", 4 ) == 0  ) {
            maxLine = start;
            break;
        }
        useline = start - currLine;
        if( useline >= use->height || start >= end ) {
            break;
        }
        /* if it is the first time in,
           then the old currfield is right
        */
        processLine( helpInBuf, helpOutBuf, useline + use->row, changecurr );
        putline( helpOutBuf, useline + use->row );
    }
    end = currLine + use->height;
    if( maxLine != 0 && end > maxLine ) {
        end = maxLine;
    }
    display_fields();
    hotSpots[1].startcol = ( helpScreen.area.width - hotSpots[1].length ) / 2;
    addSearchButton( helpSearchHdl != NULL );
    uiposnhotspots( &helpScreen, hotSpotFields );
    uiprinthotspots( &helpScreen, hotSpotFields );
    set_slider( currLine );
    uirefresh();
    return( currLine );
}
Ejemplo n.º 2
0
static void super_block_display (void)
{
	display_fields(Super_block);
}
Ejemplo n.º 3
0
static void head_display (void)
{
	display_fields(Head);
}
Ejemplo n.º 4
0
static void timeval_display (void)
{
	display_fields(Timeval);
}
Ejemplo n.º 5
0
static void inode_display (void)
{
	display_fields(Inode);
}