proc SCHEMATIC_counter_with_reset {} {
make input -name clk -origin {310 -80}
make input -name reset -origin {310 -20}
make output -name count -origin {410 -80}
}

proc ICON_counter_with_reset args {
  icon_setup $args {{origin {0 0}} {orient R0} {name x}}
icon_term -type input -origin {-80 0} -name clk
icon_term -type input -origin {-80 20} -name reset
icon_term -type output -origin {80 0} -name count
icon_property -origin {-70 0} -label clk
icon_property -origin {-70 20} -label reset
icon_property -origin {70 0} -anchor e -label count
icon_property -origin {-70 -50} -label {$name}
icon_property -origin {-70 -30} -label counter_with_reset
  icon_line -80 -40 80 -40 80 40 -80 40 -80 -40
  icon_property -origin {-90 110} -type user -name name -default x
}

