/* <<< Start of information >>>                                       */
/* ------------------------------------------------------------------ */
/* This file is part of the xwatch program. Copyright (C) Karel Kubat */
/* 1995. All rights reserved. You are permitted to redistribute this  */
/* package, if you include all unmodified sources and all unmodified  */
/* documentation (including this text). You are NOT permitted to      */
/* distribute files of this package with modifications. See the file  */
/* COPYING for more information. When in doubt, mail me at            */
/* karel@icce.rug.nl.                                                 */
/* ------------------------------------------------------------------ */
/* <<< End of information >>>                                         */

#include "xwatch.h" 

void create_options_form (void)
{
    FL_OBJECT
	*obj;
    
    options_form = fl_bgn_form (FL_NO_BOX, 275, 320);
    
    obj = fl_add_box (FL_FLAT_BOX, 0, 0, 275, 320,"");
    fl_set_object_color (obj, FL_DARKCYAN, FL_COL1);
    
    obj = fl_add_button (FL_NORMAL_BUTTON, 10, 15, 65, 25,"OK");
    fl_set_object_lsize (obj, FL_NORMAL_SIZE);
    fl_set_object_callback (obj, ok_button_callback, 0);
    
    obj = fl_add_button (FL_NORMAL_BUTTON, 200, 15, 65, 25,"Quit");
    fl_set_object_lsize (obj, FL_NORMAL_SIZE);
    fl_set_object_callback (obj, quit_button_callback, 0);
    
    obj = fl_add_button (FL_NORMAL_BUTTON, 105, 15, 65, 25, "Rescan");
    fl_set_object_lsize (obj, FL_NORMAL_SIZE);
    fl_set_object_callback (obj, rescan_button_callback, 0);
    
    obj = fl_add_button (FL_NORMAL_BUTTON, 10, 250, 45, 20, "Tiny");
    fl_set_object_callback (obj, tiny_font_button_callback, 0);
    
    obj = fl_add_button (FL_NORMAL_BUTTON, 80, 250, 45, 20,"Small");
    fl_set_object_callback (obj, small_font_button_callback, 0);
    
    obj = fl_add_button (FL_NORMAL_BUTTON, 150, 250, 45, 20, "Normal");
    fl_set_object_callback (obj, normal_font_button_callback, 0);
    
    obj = fl_add_button (FL_NORMAL_BUTTON, 220, 250, 45, 20,"Medium");
    fl_set_object_callback (obj, medium_font_button_callback, 0);
    
    obj = fl_add_text (FL_NORMAL_TEXT, 15, 270, 250, 20, "Used font");
    fl_set_object_color (obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lsize (obj, FL_NORMAL_SIZE);
    fl_set_object_lalign (obj, FL_ALIGN_CENTER);
    
    obj = fl_add_slider (FL_HOR_SLIDER, 10, 135, 255, 20, "");
    fl_set_slider_bounds (obj, 10, 1000);
    fl_set_slider_value (obj, (double) nlines);
    fl_set_object_lsize (obj, FL_NORMAL_SIZE);
    fl_set_object_callback (obj, lines_slider_callback, 0);
    
    obj = fl_add_slider (FL_HOR_SLIDER, 10, 195, 255, 20, "");
    fl_set_slider_bounds (obj, 1, 30);
    fl_set_slider_value (obj, (double) interval);
    fl_set_object_lsize (obj,FL_NORMAL_SIZE);
    fl_set_object_callback (obj,interval_slider_callback,0);
    
    obj = fl_add_text (FL_NORMAL_TEXT, 10, 155, 30, 15, "10");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    
    obj = fl_add_text (FL_NORMAL_TEXT, 10, 215, 40, 15,"1");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);

    obj = fl_add_text (FL_NORMAL_TEXT, 225, 155, 40, 15, "1000");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lalign(obj,FL_ALIGN_RIGHT);
    
    obj = fl_add_text (FL_NORMAL_TEXT, 225, 215, 40, 15, "30");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lalign(obj,FL_ALIGN_RIGHT);
    
    obj = fl_add_text (FL_NORMAL_TEXT, 40, 155, 185, 15, "Stored lines");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lsize(obj,FL_NORMAL_SIZE);
    fl_set_object_lalign(obj,FL_ALIGN_CENTER);
    
    obj = fl_add_text (FL_NORMAL_TEXT, 45, 215, 185, 15, "Scanning interval");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lsize(obj,FL_NORMAL_SIZE);
    fl_set_object_lalign(obj,FL_ALIGN_CENTER);
    
    obj = fl_add_text (FL_NORMAL_TEXT, 25, 290, 235, 25,"Xwatch Options");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lcol(obj,FL_WHITE);
    fl_set_object_lsize(obj,FL_MEDIUM_SIZE);
    fl_set_object_lalign(obj,FL_ALIGN_CENTER);
    fl_set_object_lstyle(obj,FL_BOLDITALIC_STYLE);
    
    obj = fl_add_slider (FL_HOR_SLIDER, 10, 75, 255, 20, "");
    fl_set_slider_bounds (obj, 10, 1000);
    fl_set_slider_value (obj, (double) linelen);
    fl_set_object_lsize (obj, FL_NORMAL_SIZE);
    fl_set_object_callback (obj, linelen_slider_callback, 0);
    
    obj = fl_add_text(FL_NORMAL_TEXT,10,95,30,15,"10");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    
    obj = fl_add_text(FL_NORMAL_TEXT,225,95,40,15,"1000");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lalign(obj,FL_ALIGN_RIGHT);
    
    obj = fl_add_text(FL_NORMAL_TEXT,40,95,185,15,"Line length");
    fl_set_object_color(obj,FL_DARKCYAN,FL_MCOL);
    fl_set_object_lsize(obj,FL_NORMAL_SIZE);
    fl_set_object_lalign(obj,FL_ALIGN_CENTER);

    fl_end_form();
}

