# script pour crer une prsentation au Bridge
#
Options {
  PaperSize 4     # A4
  Limits {
    # not Shown
    #Landscape
    # Default
  }
  Grid {
    Spacing 1
    Divisions 2
    # Rectangular
    # no AutoAdjust
    # not Shown
    Lock # no Lock
    # centimetre default
  }
  Zoom {
    Ratio 1 1
    # no Lock
  }
  # toolbox present
  Mode Select
  UndoSize 8192
}

FontTable {
  1 "Homerton.Medium"
  2 "Sidney"
}


# box pour un point cardinal
# text  %m
define box [ %x0 %y0 %w %h %m %piq %coe %car %tre ] {
  path {
    FillColour none
    OutlineColour r0g0b0
    Width 0.5
	Move  %x0   ( %y0 + %h - 10 )
	Line  ( %x0 + %w )   ( %y0 + %h - 10  )

	Move  %x0   ( %y0  + 12 )
	Line  ( %x0 + %w )   ( %y0  + 12  )
  }
#lgende
	Text {
	  CentreAt  ( %x0 + %w / 2 ) ( %y0 + %h )
	  Size  12 12
	  Style 1
	  Text %m
	}
	Text {
	  StartAt  ( %x0 + 10 ) ( %y0  )
	  Size  12 12
	  Style 1
	  Text "H"
	}

	Text {
	  StartAt  ( %x0 + 40 ) ( %y0  )
	  Size  12 12
	  Style 1
	  Text "HL"
	}
# couleurs
	Text {
	  colour red
	  StartAt  ( %x0 + 5 ) ( %y0 + 60 )
	  Size  16 16
	  Style 2
	  Text ""
	}

	Text {
	  colour black
	  StartAt  ( %x0 + 5 ) ( %y0 + 45 )
	  Size  16 16
	  Style 2
	  Text ""
	}

	Text {
	  colour red
	  StartAt  ( %x0 + 5 ) ( %y0 + 30 )
	  Size  16 16
	  Style 2
	  Text ""
	}

	Text {
	  colour black
	  StartAt  ( %x0 + 5 ) ( %y0 + 15 )
	  Size  16 16
	  Style 2
	  Text ""
	}
#mains
	Text {
	  colour black
	  StartAt  ( %x0 + 20 ) ( %y0 + 60 )
	  Size  12 12
	  Style 1
	  Text %piq
	}

	Text {
	  StartAt  ( %x0 + 20 ) ( %y0 + 45 )
	  Size  12 12
	  Style 1
	  Text %coe
	}

	Text {
	  StartAt  ( %x0 + 20 ) ( %y0 + 30 )
	  Size  12 12
	  Style 1
	  Text %car
	}

	Text {
	  StartAt  ( %x0 + 20 ) ( %y0 + 15 )
	  Size  12 12
	  Style 1
	  Text %tre
	}
}


#Drawing
  set $CardSud "Sud"
  set $CardEst "Est"
  set $CardOuest "Ouest"
  set $CardNord "Nord"

  set $piques "10 8 7 6 5"
  set $coeurs "R 10 9"
  set $carreaux "D 4 2"
  set $trefles "7 6 "
  group {
  name "coeurs"
  set $posX  100
  set $posY  100
  box [ $posX $posY 100 80 $CardSud $piques $coeurs $carreaux $trefles ]
  }


