!******************************************************************************!
! Test case description/purpose: i.e. NeXtMidas interactive test macro template
!
! Arguments: None
!
! Note1: The standard Window (X,Y) position should be set to (25,25) in the .mmp
!        configuration file.
!
! @bug      2511 PANEL: graphics glitches when placing panes
! @author:  JC4 / J Bauer
! @version: $Id: test_panel_stray_lines.mm,v 1.1 2011/11/18 19:53:56 jwb Exp $
!******************************************************************************!
startmacro
  switch INTERACTIVE interAct GET DEF=TRUE  SDEF=TRUE  ! for normal interactive test(s)
  switch BASELINE    baseline GET DEF=FALSE SDEF=TRUE  ! for defects or more obscure test case(s)

  if interAct then
    set instructions "You should not see any extra thin colored lines drawn at the &
                      borders of any of the panes. Do not resize these panes..."

    pipe on
      panel/msgid=MAIN/setup/controls=gc
      gcontrol label macro "Test MACRO"
      gcontrol menu  main "Exit with Status =" "PASS,FAIL" TABLE={ItemColors={PASS="GREEN",FAIL="RED"}} 

      gcontrol text  idtext "Instructions" instructions 24 12 /title

      plot/id=signal readout=+OnAxis|+ExtPrec
      plot/id=fft    readout=+OnAxis|+ExtPrec cm=Mag
      plot/id=fft0   readout=+OnAxis|+ExtPrec cm=Mag
      plot/id=hist   readout=+OnAxis|+ExtPrec /ALL
      list2/id=stat
      
    pipe off

  endif
endmacro

!******************************************************************************!
! Main process message for this macro. Should be right after the ENDMACRO.
procedure processMessage m:msg
  if msg.name eqs "MAIN" then
    assert/text="^reg.main.name: User indicated tests" msg.data eqss "PASS"
    pipe stop
  else
    say "Unhandled message name: ^msg.name from fid: ^msg.fid data: ^msg.data"
  endif
return

!******************************************************************************!
! If an unexpected exception is caught, mark test as failed
!******************************************************************************!
procedure processException m:emsg
  assert/text="^reg.main.name: Caught unexpected exception ^{emsg.data}" "FALSE" isTrue
  if "Trace" SUBS ENV.DEBUG invoke ,, emsg.data.printStackTrace()
return

!******************************************************************************!
! Sample test procedure description
procedure test_xyz

return
