/*
    gr_by_axis_advanced.dlg
    
*!  VERSION 1.0.0  21aug2006

	// SCRIPTS and PROGRAMS for external use
	   * SCRIPT setAxis_x
	   * SCRIPT setAxis_y

	/* Called by x and y axis tabs */

*/

VERSION 10.0

INCLUDE _std_small
DEFINE _dlght 180
INCLUDE header_gr_child

DEFINE _vnwd 100
DEFINE _vnsep +105

DEFINE _clwd	15
DEFINE _wd	150
DEFINE _sep	+155
DEFINE _cbwd	130
DEFINE _cbsep	+135

SCRIPT PREINIT
BEGIN
	create LIST axes_rescale
	create LIST axes_iaxes
	create LIST axes_itick
	create LIST axes_ilabel
	create LIST axes_ititle
END

SCRIPT setAxis_x
BEGIN
	axes_rescale.Arrdropall
	axes_rescale.Arrpush ""
	axes_rescale.Arrpush "xrescale"
	axes_rescale.Arrpush "noxrescale"
	axes.cb_rescale.withvalue axes.cb_rescale.setvalue "@"
	
	axes_iaxes.Arrdropall
	axes_iaxes.Arrpush ""
	axes_iaxes.Arrpush "ixaxes"
	axes_iaxes.Arrpush "noixaxes"
	axes.cb_iaxes.withvalue axes.cb_iaxes.setvalue "@"

	axes_itick.Arrdropall
	axes_itick.Arrpush ""
	axes_itick.Arrpush "ixtick"
	axes_itick.Arrpush "noixtick"
	axes.cb_itick.withvalue axes.cb_itick.setvalue "@"

	axes_ilabel.Arrdropall
	axes_ilabel.Arrpush ""
	axes_ilabel.Arrpush "ixlabel"
	axes_ilabel.Arrpush "noixlabel"
	axes.cb_ilabel.withvalue axes.cb_ilabel.setvalue "@"

	axes_ititle.Arrdropall
	axes_ititle.Arrpush ""
	axes_ititle.Arrpush "ixtitle"
	axes_ititle.Arrpush "noixtitle"
	axes.cb_ititle.withvalue axes.cb_ititle.setvalue "@"
END

SCRIPT setAxis_y
BEGIN
	axes_rescale.Arrdropall
	axes_rescale.Arrpush ""
	axes_rescale.Arrpush "yrescale"
	axes_rescale.Arrpush "noyrescale"
	axes.cb_rescale.withvalue axes.cb_rescale.setvalue "@"

	axes_iaxes.Arrdropall
	axes_iaxes.Arrpush ""
	axes_iaxes.Arrpush "iyaxes"
	axes_iaxes.Arrpush "noiyaxes"
	axes.cb_iaxes.withvalue axes.cb_iaxes.setvalue "@"

	axes_itick.Arrdropall
	axes_itick.Arrpush ""
	axes_itick.Arrpush "iytick"
	axes_itick.Arrpush "noiytick"
	axes.cb_itick.withvalue axes.cb_itick.setvalue "@"

	axes_ilabel.Arrdropall
	axes_ilabel.Arrpush ""
	axes_ilabel.Arrpush "iylabel"
	axes_ilabel.Arrpush "noiylabel"
	axes.cb_ilabel.withvalue axes.cb_ilabel.setvalue "@"

	axes_ititle.Arrdropall
	axes_ititle.Arrpush ""
	axes_ititle.Arrpush "iytitle"
	axes_ititle.Arrpush "noiytitle"
	axes.cb_ititle.withvalue axes.cb_ititle.setvalue "@"
END

HELP hlp1, view("help by_option")
RESET res1

DIALOG axes, tabtitle("Axes") 					///
	title("Advanced axis options for subgraphs")
BEGIN
  TEXT     tx_rescale		_lft	20	_wd	.,	///
	label("Rescale:") right
  COMBOBOX cb_rescale		_sep	@	_cbwd	.,	///
	dropdownlist contents(yesno) values(axes_rescale)
	
  TEXT     tx_iaxes		_lft	_mls	_wd	.,	///
	label("Show axis:") right
  COMBOBOX cb_iaxes		_sep	@	_cbwd	.,	///
	dropdownlist contents(yesno) values(axes_iaxes)

  TEXT     tx_itick		_lft	_mls	_wd	.,	///
	label("Show ticks:") right
  COMBOBOX cb_itick		_sep	@	_cbwd	.,	///
	dropdownlist contents(yesno) values(axes_itick)
	
  TEXT     tx_ilabel		_lft	_mls	_wd	.,	///
	label("Show labels:") right
  COMBOBOX cb_ilabel		_sep	@	_cbwd	.,	///
	dropdownlist contents(yesno) values(axes_ilabel)

  TEXT     tx_ititle		_lft	_mls	_wd	.,	///
	label("Show titles:") right
  COMBOBOX cb_ititle		_sep	@	_cbwd	.,	///
	dropdownlist contents(yesno) values(axes_ititle)
END

PROGRAM command
BEGIN
	put " " axes.cb_rescale
	put " " axes.cb_iaxes
	put " " axes.cb_itick
	put " " axes.cb_ilabel
	put " " axes.cb_ititle
END
