#list_of_things=['point','line','segment','circle','function','polygon','cone','ellipse','polynomial']
#toolbar=0 , 1 , 10 , 16 , 6
plaatje=0
n=$teller
debug=1
bewerking=nivo/bewerking2.proc
woordmax=300
maxobjects=100
charmax=300
showToolBar=true
showMenuBar=true
framePossible=true
number_of_buttons=1
buttontext1=!record 4 of common/commonremarks.$taal  
lijn=!record 67 of lang/remarks.$taal
width=640
height=480
# hoeveel lijnen verwachten we?
lines=1
R=$graad
!if $graad=0
    R=$teller
!endif
# ggb=../../../../$module_dir/nivo/grid.ggb
ggb=../nivo/grid.ggb

keuze=!randitem 0,1
!if $R=1
    list_of_things=[ 'line' ];
    toolbar=2 | 0 | 6 | 40   
    appletcommand=$empty
    somtekst$n=!record 12 of lang/remarks.$taal
    # prefix my_ maakt dat geogebra2wims.js ze niet ook opstuurt
    # GEOGEBRA: lijn  => name @ slope @ constant                                                                                                          
    # GEOGEBRA: lijn  =>  name @ perp @ x=number
    #appletcommand=!append line document.applets[0].evalCommand("$B = ($x,$y)"); to $appletcommand
    #appletcommand=!append line document.applets[0].evalCommand("$name = vector[My_A,$B]"); to $appletcommand
    #appletcommand=!append line document.applets[0].setVisible('$B' , false ); to $appletcommand
    #appletcommand=!append line document.applets[0].setColor('$name',255,0,0); to $appletcommand
    a=!randitem -5,-4,-3,-2,-1,1,2,3,4,5
    !if $keuze=0
	opgave$n=Re\left( z \right)\,\,=\,\, $a
	GOED$n=perp,$a
	goed$n=$lijn \,Re\,=\,$a
    !else
	opgave$n=Im\left( z \right)\,\,=\,\, $a
	GOED$n=0,$a
	goed$n=$lijn \,Im\,=\,$a
    !endif
 !exit
!endif

!if $R=2
    list_of_things=[ 'line' ];
    toolbar=2 | 0 | 6 | 40   
    appletcommand=$empty
    somtekst$n=!record 12 of lang/remarks.$taal
    # prefix my_ maakt dat geogebra2wims.js ze niet ook opstuurt
    #appletcommand=!append line document.applets[0].evalCommand("$B = ($x,$y)"); to $appletcommand
    #appletcommand=!append line document.applets[0].evalCommand("$name = vector[My_A,$B]"); to $appletcommand
    #appletcommand=!append line document.applets[0].setVisible('$B' , false ); to $appletcommand
    #appletcommand=!append line document.applets[0].setColor('$name',255,0,0); to $appletcommand
    a=!randitem -3,-2,-1,1,2,3
    !if $keuze=0
	opgave$n=$a \cdot Im\left( z \right)\,\,=\,\, Re\left( z \right)
	GOED$n=1/$a,0
	goed$n=$lijn \,Im\,=\,\frac{1}{$a} \cdot Re
    !else
	opgave$n=$a \cdot Re\left( z \right)\,\,=\,\, Im\left( z \right)
	GOED$n=$a,0
	goed$n=$lijn \,Im\,=\,$a \cdot Re
    !endif
 !exit
!endif

!if $R>2
    list_of_things=[ 'line' ];
    toolbar=2 | 0 | 6 | 40   
    appletcommand=$empty
    somtekst$n=!record 12 of lang/remarks.$taal
    # prefix my_ maakt dat geogebra2wims.js ze niet ook opstuurt
    #appletcommand=!append line document.applets[0].evalCommand("$B = ($x,$y)"); to $appletcommand
    #appletcommand=!append line document.applets[0].evalCommand("$name = vector[My_A,$B]"); to $appletcommand
    #appletcommand=!append line document.applets[0].setVisible('$B' , false ); to $appletcommand
    #appletcommand=!append line document.applets[0].setColor('$name',255,0,0); to $appletcommand
    a=!randitem 2,3,1/2,1/3,1/4,4,1/5,2/3,3/4,2/5,3/5
    b=!randitem -3,-2,-1,1,2,3
    !if $keuze=0
	opgave$n=Im\left( z \right)\, - \, $a \cdot Re\left( z \right)\,\,=\,\,$b
	GOED$n=$a,$b
	goed$n=$lijn \,Im\,=\,$a \cdot Re \,+\,$b
    !else
	opgave$n=Im\left( z \right)\, + \, $a \cdot Re\left( z \right)\,\,=\,\,$b
	GOED$n=$[-1*$a],$b
	goed$n=$lijn \,Im\,=\,-$a \cdot Re \,+\,$b
    !endif
 !exit
!endif

#!if $R>1
#    list_of_things=[ 'circle' ];
#    toolbar=34 | 0 | 6    
#    appletcommand=$empty
#    # prefix my_ maakt dat geogebra2wims.js ze niet ook opstuurt
#    #appletcommand=!append line document.applets[0].evalCommand("$B = ($x,$y)"); to $appletcommand
#    #appletcommand=!append line document.applets[0].evalCommand("$name = vector[My_A,$B]"); to $appletcommand
#    #appletcommand=!append line document.applets[0].setVisible('$B' , false ); to $appletcommand
#    #appletcommand=!append line document.applets[0].setColor('$name',255,0,0); to $appletcommand
#    somtekst$n=
#    opgave$n=
#    GOED$n=
#    goed$n=
# !exit
#!endif
#
