/*
  Include file for axes tab. Used with easy graph dialogs

  VERSION 1.0.1  31mar2005

*/

DIALOG eaxes, label("") tabtitle("Axes")
BEGIN

  GROUPBOX gb_xaxis    _lft        _top      _comb4_1    _ht12h,	///
  	label("X-Axis")
 DEFINE y @y
  TEXT     tx_xtitle   _ilft       _ms       _txwd       .,		///
 	label("Title:") right
  EDIT     ed_xtitle   _txsep      @         _vllwd      .,		///
 	label("X-Title")
  TEXT     tx_xsize    _ilft       _ms       _txwd       .,		///
  	label("Title size:") right
  COMBOBOX cb_xsize    _txsep      @         _cbwd       ., 		///
  	label("X-Axis Size")						///
  	dropdownlist contents(textsizes)				///
  	option(size)
  TEXT     tx_xrule    _ilft       _xxls     _txwd       .,		///
 	label("Tick rule:") right
  EDIT     ed_xrule    _txsep      @         _vllwdmbu   .,		///
 	label("X-Tick rule")
  BUTTON   bu_xrule    _vllwdbusep @         _btwd       .,		///
  	label("?")							///
  	onpush(view help major_tick_rule##|_new)
  TEXT     tx_xlog     _ilft       _ms       _txwd       ., label("")
  CHECKBOX ck_xlog     _txsep      @         _vllwd      .,		///
  	label("Log axis scale")

  GROUPBOX gb_yaxis    _lft        _xls      _comb4_1    _ht12h,	///
  	label("Y-Axis")
  TEXT     tx_ytitle   _ilft       _ms       _txwd       .,		///
 	label("Title:") right
  EDIT     ed_ytitle   _txsep      @         _vllwd      .,		///
 	label("Y-Title")
  TEXT     tx_ysize    _ilft       _ms       _txwd       .,		///
  	label("Title size:") right
  COMBOBOX cb_ysize    _txsep      @         _cbwd       ., 		///
  	label("Y-Axis Size")						///
  	dropdownlist contents(textsizes)				///
  	option(size)
  TEXT     tx_yrule    _ilft       _xxls     _txwd       .,		///
 	label("Tick rule:") right
  EDIT     ed_yrule    _txsep      @         _vllwdmbu   .,		///
 	label("Y-Tick rule")
  BUTTON   bu_yrule    _vllwdbusep @         _btwd       .,		///
  	label("?")							///
  	onpush(view help major_tick_rule##|_new)
  TEXT     tx_ylog     _ilft       _ms       _txwd       ., label("")
  CHECKBOX ck_ylog     _txsep      @         _vllwd      .,		///
  	label("Log axis scale")

END

PROGRAM eaxes_xtitle_opts
BEGIN
	beginoptions
		optionarg eaxes.cb_xsize
	endoptions
END

PROGRAM eaxes_ytitle_opts
BEGIN
	beginoptions
		optionarg eaxes.cb_ysize
	endoptions
END

PROGRAM eaxes_output
BEGIN
  if eaxes.ed_xtitle | eaxes.cb_xsize {
  	put " " "xtitle("
  	put eaxes.ed_xtitle
  	put /program eaxes_xtitle_opts
  	put ") "
  }
  if eaxes.ed_xrule {
  	put " " "xlabel("
  	put eaxes.ed_xrule
  	put ") "
  }
  if eaxes.ck_xlog{
  	put " " "xscale(log) "
  }

  if eaxes.ed_ytitle | eaxes.cb_ysize {
  	put " " "ytitle("
  	put eaxes.ed_ytitle
  	put /program eaxes_ytitle_opts
  	put ") "
  }
  if eaxes.ed_yrule {
  	put " " "ylabel("
  	put eaxes.ed_yrule
  	put ") "
  }
  if eaxes.ck_ylog{
  	put " " "yscale(log) "
  }
END

