<plugin resizable="true">
	<hbox spacing="4">
		<vbox spacing="4" expand="true">
			<!-- Fast Control -->
				<align halign="-1">
						<button id="freeze" text="actions.freeze" ui:inject="Button_cyan" height="22" bg.color="bg_schema" pad.h="6" pad.v="4"/>
				</align>

			<group ui:inject="GraphGroup" ipadding="0" expand="true" fill="true" text="labels.graphs.oscilloscope">
				<graph width.min="550" height.min="550" expand="true">
					<!-- Origin -->
					<origin halign="0.0" valign="0.0" visible="false"/>

					<!-- Alt 2 color -->
					<ui:for id="i" first="-31" last="31">
						<ui:if test=":i mod 4">
							<marker v="${:i * 0.03125}" ox="1" oy="0" color="graph_alt_4"/>
							<marker v="${:i * 0.03125}" color="graph_alt_4"/>
						</ui:if>
					</ui:for>

					<!-- Alt 1 color -->
					<ui:for id="i" first="-7" last="7">
						<ui:if test=":i mod 4">
							<marker v="${:i * 0.125}" ox="1" oy="0" color="graph_alt_1"/>
							<marker v="${:i * 0.125}" color="graph_alt_1"/>
						</ui:if>
					</ui:for>

					<marker v="0" dy=":_a_width" dx="+:_a_height" color="graph_alt_1" smooth="true"/>
					<marker v="0" dy=":_a_width" dx="-:_a_height" color="graph_alt_1" smooth="true"/>

					<!-- Secondary color -->
					<ui:for id="i" first="-1" last="1">
						<ui:if test=":i mod 2">
							<marker v="${:i * 0.5}" ox="1" oy="0" color="graph_sec"/>
							<marker v="${:i * 0.5}" color="graph_sec"/>
						</ui:if>
					</ui:for>

					<!-- Axes -->
					<axis min="-1.0" max="1.0" color="graph_prim" angle="0.0" log="false"/>
					<axis min="-1.0" max="1.0" color="graph_prim" angle="0.5" log="false"/>

					<!-- Streams -->
					<stream id="oscv_1" width="2" color="graph_mesh" smooth="true" strobe="true" strobes=":sh_sz" dots.max=":maxdots"/>

					<!-- Trigger References -->
					<marker
						v=":trlv_1 * 0.01 + :veps_1 * 0.01"
						basis="1"
						parallel="0"
						color="graph_marker"
						visibility="(:scmo_1 ieq 1) and ((:trtp_1 ieq 1) or (:trtp_1 ieq 2))"/>
					<marker
						v=":trlv_1 * 0.01 + :veps_1 * 0.01 - 2 * :trhy_1 * 0.01"
						ox="1"
						oy="0"
						color="graph_marker"
						visibility="(:scmo_1 ieq 1) and ((:trtp_1 ieq 3) or (:trtp_1 ieq 4))"/>
					<marker
						v=":trlv_1 * 0.01 + :veps_1 * 0.01 + 2 * :trhy_1 * 0.01"
						ox="1"
						oy="0"
						color="graph_marker" visibility="(:scmo_1 ieq 1) and ((:trtp_1 ieq 3) or (:trtp_1 ieq 4))"/>
					<marker
						v=":hzps_1 * 0.01"
						color="graph_marker"
						visibility=":scmo_1 ieq 1"/>

					<!-- Text -->
					<ui:with y="-1" halign="1" valign="1">
						<text x="-1" text="graph.axis.x"/>
						<text x="-0.75" text="-0.75"/>
						<text x="-0.5" text="-0.5"/>
						<text x="-0.25" text="-0.25"/>
						<text x="0" text="0"/>
						<text x="0.25" text="0.25"/>
						<text x="0.5" text="0.5"/>
						<text x="0.75" text="0.75"/>
						<text x="1" text="1" halign="-1"/>
					</ui:with>

					<ui:with x="-1" halign="1" valign="-1">
						<text y="-0.75" text="-0.75"/>
						<text y="-0.5" text="-0.5"/>
						<text y="-0.25" text="-0.25"/>
						<text y="0" text="0"/>
						<text y="0.25" text="0.25"/>
						<text y="0.5" text="0.5"/>
						<text y="0.75" text="0.75"/>
						<text y="1" text="graph.axis.y"/>
					</ui:with>
				</graph>
			</group>

			<hbox>
				<hbox bg.color="bg_schema" pad.v="4" pad.h="6" spacing="6">
					<label text="labels.history"/>
					<fader id="sh_sz" angle="0" expand="true"/>
					<value id="sh_sz" sline="true" width="12"/>
				</hbox>
				<vsep pad.h="2" bg.color="bg" hreduce="true"/>
				<hbox bg.color="bg_schema" pad.v="4" pad.h="6" spacing="6">
					<label text="labels.oscilloscope.xy_sweep"/>
					<fader id="xyrt" angle="0" expand="true"/>
					<value id="xyrt" sline="true" width="40"/>
				</hbox>
				<vsep pad.h="2" bg.color="bg" hreduce="true"/>
				<hbox bg.color="bg_schema" pad.v="4" pad.h="6" spacing="6">
					<label text="labels.oscilloscope.max_dots"/>
					<fader id="maxdots" angle="0" expand="true"/>
					<value id="maxdots" sline="true" width="30"/>
				</hbox>
			</hbox>

			<!-- Params -->
			<align halign="-1">
				<hbox bg.color="bg_schema" >
						<hbox spacing="4" pad.h="6" pad.v="4">
							<label text="labels.oscilloscope.H_orizontal" font.size="10"/>
							<vsep color="text_prim" hreduce="true"/>
							<label text="labels.oscilloscope.V_ertical" font.size="10"/>
							<vsep color="text_prim" hreduce="true"/>
							<label text="labels.oscilloscope.T_ime" font.size="10"/>
						</hbox>


					<void bg.color="bg" width="4" hreduce="true"/>

						<hbox spacing="2" height="10" pad.h="6">
								<value id="hzdv_1" sline="true" font.size="10" color="cyan" width="30" />
							<vsep color="cyan" hreduce="true"/>
								<value id="vedv_1" sline="true" font.size="10" color="cyan" width="30" />
							<vsep color="cyan" hreduce="true"/>
								<value id="tmdv_1" sline="true" font.size="10" color="cyan" width="50" />
						</hbox>
					<void bg.color="bg" width="4" hreduce="true"/>
				</hbox>
			</align>
		</vbox>

		<!-- Channels -->
		<grid rows="21" cols="4">

				<!-- Row 1 -->
				<align halign="1">
					<label bg.color="bg_schema" text="groups.oscilloscope.operation" pad.h="6"/>
				</align>
				<cell rows="21">
					<void bg.color="bg" width="4" hreduce="true"/>
				</cell>
				<cell bg.color="osc_bg_gray" cols="2">
					<label bg.color="bg_schema"/>
				</cell>

        		<!-- Row 2 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.oversampler_mode" pad.h="6"/>
				</align>
				<cell cols="2">
					<combo id="ovmo_1" bg.color="osc_bg_gray" pad.h="6"/>
				</cell>

				<!-- Row 3 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.mode" pad.h="6"/>
				</align>
				<cell cols="2">
					<combo id="scmo_1" bg.color="osc_bg_gray"  pad.h="6" pad.b="1"/>
				</cell>

				<!-- Row 4 -->
				<void color="bg" height="4" vreduce="true"/>
				<cell cols="2">
					<void color="bg" height="4" vreduce="true"/>
				</cell>

				<!-- Row 5 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.sweep_type" pad.h="6"/>
				</align>
				<cell cols="2">
					<combo id="swtp_1" bg.color="osc_bg_gray" pad.h="6" pad.t="1"/>
				</cell>

				<!-- Row 6 -->
				<void bg.color="bg_schema"/>
				<label text="labels.oscilloscope.division" bg.color="osc_bg_gray" />
				<label text="labels.oscilloscope.position" bg.color="osc_bg_gray" />

				<!-- Row 7 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.horizontal" pad.h="6"/>
				</align>
				<hbox>
					<knob id="hzdv_1" size="25" bg.color="osc_bg_gray" visibility=":scmo_1 ine 1"/>
					<knob id="tmdv_1" size="25" bg.color="osc_bg_gray" visibility=":scmo_1 ieq 1"/>
				</hbox>
				<knob id="hzps_1" size="25" bg.color="osc_bg_gray"/>

				<!-- Row 8 -->
				<void bg.color="bg_schema"/>
				<hbox >
					<value id="hzdv_1" sline="true" bg.color="osc_bg_gray" visibility=":scmo_1 ine 1"/>
					<value id="tmdv_1" sline="true" bg.color="osc_bg_gray" visibility=":scmo_1 ieq 1"/>
				</hbox>
				<value id="hzps_1" sline="true" bg.color="osc_bg_gray"/>

				<!-- Row 9 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.vertical" pad.h="6"/>
				</align>
				<knob id="vedv_1" size="25" bg.color="osc_bg_gray"/>
				<knob id="veps_1" size="25" bg.color="osc_bg_gray"/>

				<!-- Row 10 -->
				<void bg.color="bg_schema"/>
				<value id="vedv_1" sline="true" bg.color="osc_bg_gray" pad.b="2"/>
				<value id="veps_1" sline="true" bg.color="osc_bg_gray" pad.b="2"/>

				<!-- Row 11 -->
				<void bg.color="bg" height="4" vreduce="true"/>
				<cell cols="2">
					<void bg.color="bg" height="4" vreduce="true"/>
				</cell>

				<!-- Row 12 -->
				<align halign="1">
					<label bg.color="bg_schema" text="groups.oscilloscope.trigger" pad.h="6"/>
				</align>
				<cell cols="2" bg.color="osc_bg_gray">
					<void bg.color="bg"/>
				</cell>

				<!-- Row 13 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.trigger_level" pad.h="6"/>
				</align>
				<knob id="trlv_1" size="25" bg.color="osc_bg_gray"/>
				<value id="trlv_1" sline="true" bg.color="osc_bg_gray"/>

				<!-- Row 14 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.trigger_hysteresis" pad.h="6"/>
				</align>
				<knob id="trhy_1" size="25" bg.color="osc_bg_gray"/>
				<value id="trhy_1" sline="true" bg.color="osc_bg_gray"/>

				<!-- Row 15 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.trigger_hold_time" pad.h="6"/>
				</align>
				<knob id="trho_1" size="25" bg.color="osc_bg_gray"/>
				<value id="trho_1" sline="true" bg.color="osc_bg_gray"/>

				<!-- Row 16 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.trigger_input" pad.h="6"/>
				</align>
					<combo id="trin_1" fill="false" bg.color="osc_bg_gray" width="55" pad.h="6"/>
					<align halign="1">
						<button id="trre_1" text="actions.run_stop" ui:inject="Button_gray" pad.r="6" hfill="false" width="55" height="22" bg.color="osc_bg_gray" editable="(:trmo_1 ilt 2) and (:scmo_1 ieq 1))" pointer="((:trmo_1 ilt 2) and (:scmo_1 ieq 1)) ? 'hand' : 'arrow'" bright="((:trmo_1 ilt 2) and (:scmo_1 ieq 1)) ? 1 : 0.75"/>
						</align>

				<!-- Row 17 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.trigger_mode" pad.h="6"/>
				</align>
				<cell cols="2">
					<combo id="trmo_1" bg.color="osc_bg_gray" pad.h="6"/>
				</cell>

				<!-- Row 18 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.oscilloscope.trigger_type" pad.h="6"/>
				</align>
				<cell cols="2">
					<combo id="trtp_1" bg.color="osc_bg_gray" pad.h="6" pad.b="1"/>
				</cell>

				<!-- Row 19 -->
				<void bg.color="bg" height="4" vreduce="true"/>
				<cell cols="2">
					<void bg.color="bg" height="4" vreduce="true"/>
				</cell>

				<!-- Row 20 -->
				<align halign="1">
					<label bg.color="bg_schema" text="groups.oscilloscope.coupling" pad.h="6"/>
				</align>
				<cell cols="2" bg.color="osc_bg_gray">
					<void color="bg" height.min="4"/>
				</cell>

				<!-- Row 21 -->
				<align halign="1">
					<label bg.color="bg_schema" text="labels.X_Y_EXT" pad.h="6" />
				</align>
				<cell cols="2" bg.color="osc_bg_gray" >
					<hbox fill="true" pad.h="6" spacing="4" pad.b="1">
						<combo id="sccx_1" />
						<combo id="sccy_1" />
						<combo id="scce_1" />
					</hbox>
				</cell>
			</grid>
	</hbox>
</plugin>
