<plugin resizable="true">
	<hbox spacing="4">
		<vbox spacing="4">

			<!-- Graph, tempo and master box -->
			<hbox spacing="4">

				<!-- Graph and tempo box -->
				<vbox spacing="4">

					<!-- Graph box -->
					<hbox spacing="2">
						<vbox spacing="2" expand="true">
							<hbox>
								<label text="labels.graphs.delay_graph"/>
								<align hpos="1" expand="true">
									<hbox spacing="4">
										<label text="labels.memory:mb"/>
										<indicator id="memuse" format="f6.1!" text_color="green"/>
									</hbox>
								</align>
							</hbox>
							<graph width="320" height="75" expand="true">
								<center hpos="-1" vpos="0" visible="false"/>

								<!-- Axis -->
								<axis min="0" max=":dmaxv" color="g_white" angle="0.0" logarithmic="false"/>
								<axis min="-1" max="1" color="g_white" angle="0.5" logarithmic="false" visibility="false"/>

								<text text="graph.axis.time" basis="0;1" coord=":dmaxv;0" halign="-1" valign="-1" color="g_white"/>

								<ui:for id="i" first="0" last="15">
									<marker value=":adt${i}" basis="0" parallel="1" width="3" color="yellow" hue_id="hue${i}" visibility=":on${i}"/>
									<marker value=":adt${i} + :afbt${i}" basis="0" parallel="1" width="1" color="yellow" hue_id="hue${i}" visibility=":on${i} and :fbe${i} and :fb"/>
									<text text="${i}" basis="0;1" coord=":adt${i};1" halign="1" valign="-1" color="yellow" hue_id="hue${i}" visibility=":on${i}"/>
									<text id="adt${i}" text="labels.values.fmt_value" basis="0;1" coord=":adt${i};-1" halign="1" valign="1" color="yellow" hue_id="hue${i}" visibility=":on${i}"/>
									<text id="afbt${i}" text="labels.values.fmt_value" basis="0;1" coord=":adt${i} + :afbt${i};0" halign="1" valign="1" color="yellow" hue_id="hue${i}" visibility=":on${i} and :fbe${i} and :fb"/>
								</ui:for>
							</graph>
						</vbox>

					</hbox>

					<!-- Global Delay Controls -->
					<group text="groups.global_delay_ctr">
						<hbox>
							<grid rows="4" cols="31" spacing="4" transpose="true">
								<ui:for id="i" first="0" last="15">
									<ui:if test="${:i igt 0}">
										<cell rows="4">
											<vsep/>
										</cell>
									</ui:if>
									<label text="${i}"/>
									<align hpos="0">
										<hbox>
											<button id="on${i}" led="true" color="yellow" size="12"/>
											<label text="labels.chan.on"/>
										</hbox>
									</align>
									<align hpos="0">
										<hbox>
											<button id="s${i}" led="true" color="green" size="12"/>
											<label text="labels.chan.solo"/>
										</hbox>
									</align>
									<align hpos="0">
										<hbox>
											<button id="m${i}" led="true" color="red" size="12"/>
											<label text="labels.chan.mute"/>
										</hbox>
									</align>
								</ui:for>
							</grid>
						</hbox>
					</group>

					<!-- Tempo settings -->
					<group text="groups.tempo_settings">
						<grid rows="5" cols="31" transpose="true" spacing="2">
							<ui:for id="i" first="0" last="7">
								<!-- Separator -->
								<ui:if test="${:i igt 0}">
									<cell rows="5">
										<vsep/>
									</cell>
								</ui:if>

								<!-- BPM device -->
								<cell cols="3">
									<label text="${i}"/>
								</cell>
								<cell cols="3">
									<ttap id="tempo${i}" text="actions.tap" color="knob_scale" width="102" height="32" led="false" text_color="label_text"/>
								</cell>
								<vbox>
									<knob id="tempo${i}"/>
									<value id="tempo${i}" detailed="false" precision="2"/>
								</vbox>

								<cell cols="3">
									<align hpos="1" pad_right="4">
										<indicator id="atempo${i}" format="f6.2!" text_color="green"/>
									</align>
								</cell>
								<cell cols="3">
									<align hpos="1" pad_right="4">
										<label text_color="green" text="units.bpm"/>
									</align>
								</cell>

								<vsep/>

								<vbox>
									<align vpos="1">
										<combo id="ratio${i}" width="20"/>
									</align>
									<align vpos="1">
										<hbox>
											<button id="sync${i}" led="true" color="yellow" width="12" height="12"/><label text="labels.sync"/>
										</hbox>
									</align>
								</vbox>

							</ui:for>
						</grid>
					</group>
				</vbox>

				<!-- Master channel -->
				<vbox spacing="4">
					<group text="groups.chan.master">
						<grid rows="11" cols="2" spacing="2">

							<cell cols="2"><label text="labels.max_delay:s"/></cell>

							<cell cols="2"><combo id="dmax"/></cell>

							<cell cols="2">
								<align hpos="0">
									<hbox spacing="2">
										<button id="mono" led="true" color="yellow" size="12"/>
										<label text="labels.signal.mono"/>
									</hbox>
								</align>
							</cell>

							<cell cols="2">
								<align hpos="0">
									<hbox spacing="2">
										<button id="fb" led="true" color="knob_scale" size="12"/>
										<label text="labels.feedback"/>
									</hbox>
								</align>
							</cell>

							<knob id="fbg"/>
							<value id="fbg"/>

							<cell cols="2"><hsep/></cell>

							<vbox>
								<label text="labels.signal.dry_pan"/>
								<knob id="p_in" balance="0"/>
								<value id="p_in"/>
							</vbox>
							<vbox>
								<label text="labels.output"/>
								<knob id="g_out" balance="0"/>
								<value id="g_out"/>
							</vbox>

							<cell cols="2"><hsep/></cell>

							<align hpos="0">
								<hbox spacing="2">
									<button color="red" led="true" id="dry_on" size="12"/>
									<label text="labels.signal.dry"/>
								</hbox>
							</align>

							<align hpos="0">
								<hbox spacing="2">
									<button color="red" led="true" id="wet_on" size="12"/>
									<label text="labels.signal.wet"/>
								</hbox>
							</align>

							<knob id="dry" scale_color="yellow"/>
							<knob id="wet" scale_color="yellow"/>

							<value id="dry"/>
							<value id="wet"/>

						</grid>
					</group>
				</vbox>
			</hbox>

			<!-- Delay lines -->
			<cgroup id="lsel">
				<ui:for id="i" first="0" last="15">
					<!-- Delay line -->
					<vbox spacing="4">
						<align hpos="1" pad_bottom="4">
							<label text="labels.delay_time_formula"/>
						</align>

						<hsep color="gray"/>

						<!-- Delay formula -->
						<align hpos="1">
							<grid rows="7" cols="19" hspacing="6">
								<!-- Row 1 -->
								<cell cols="5">
									<label text="labels.delay_reference"/>
								</cell>
								<void/>
								<cell cols="9">
									<label text="labels.tempo_based_delay"/>
								</cell>
								<void/>
								<label text="labels.delay"/>
								<void/>
								<label text="labels.result"/>

								<!-- Row 2 -->
								<label text="[" font_size="22"/>
								<vbox>
									<value id="dval${i}" visibility="!:loop${i}" font_size="22" same_line="true"/>
									<value id="dval${i}" color="red" visibility=":loop${i}" font_size="22" same_line="true"/>
								</vbox>
								<label text="x" font_size="22"/>
								<value id="drefm${i}" width="55" font_size="22" same_line="true"/>
								<label text="]" font_size="22"/>
								<label text="+" font_size="22"/>
								<label text="[" font_size="22"/>
								<value id="tval${i}" precision="2" width="130" font_size="22" same_line="true"/>
								<label text=":" font_size="22"/>
								<value id="treff${i}" read_only="true" precision="3" width="75" font_size="22" same_line="true" detailed="false"/>
								<label text="x" font_size="22"/>
								<value id="trefm${i}" width="55" font_size="22" same_line="true"/>
								<label text="+" font_size="22"/>
								<value id="frac${i}" read_only="true" precision="3" width="75" font_size="22" same_line="true" detailed="false"/>
								<label text="]" font_size="22"/>
								<label text="+" font_size="22"/>
								<value id="dadd${i}" width="110" precision="3" font_size="22" same_line="true"/>
								<label text="=" font_size="22"/>
								<vbox fill="false">
									<value id="adt${i}" width="110" precision="3" color="green" visibility="!:door${i}" font_size="22" same_line="true"/>
									<value id="adt${i}" width="110" precision="3" color="red" visibility=":door${i}" font_size="22" same_line="true"/>
								</vbox>

								<!-- Row 3 -->
								<void/>
								<combo id="dref${i}" fill="false" pad_bottom="5" width="80"/>
								<void/>
								<knob id="drefm${i}" scale_color="knob_scale" size="12" scale_hue_id="hue${i}"/>
								<void/>
								<void/>
								<void/>
								<combo id="tref${i}" fill="false" pad_bottom="5" width="64"/>
								<void/>
								<frac id="treff${i}" id2="trefd${i}" color="green"/>
								<void/>
								<knob id="trefm${i}" size="12" scale_color="knob_scale" scale_hue_id="hue${i}"/>
								<void/>
								<frac id="frac${i}" id2="den${i}" color="green"/>
								<void/>
								<void/>
								<knob id="dadd${i}" size="12" scale_color="knob_scale" scale_hue_id="hue${i}"/>
								<void/>
								<void/>

								<!-- Row 4 -->
								<cell cols="19" pad_bottom="4">
									<hsep color="gray"/>
								</cell>

								<!-- Row 5 -->
								<cell cols="6" rows="3">
									<align hpos="0" vpos="0">
										<vbox width="245" fill="false">
											<align hpos="0" visibility="!(:loop${i} or :door${i} or :fbor${i})">
												<label text="labels.warning.all_values_good" color="green"/>
											</align>
											<align hpos="0" visibility=":loop${i}">
												<label text="labels.warning.loop_in_delay" color="red"/>
											</align>
											<align hpos="0" visibility=":fbor${i}">
												<label text="labels.warning.feedback_out_of_range" color="red"/>
											</align>
											<align hpos="0" visibility=":door${i}">
												<label text="labels.warning.delay_out_of_range" color="red"/>
											</align>
										</vbox>
									</align>
								</cell>
								<cell cols="9">
									<label text="labels.tempo_based_feedback_delay"/>
								</cell>
								<void/>
								<label text="labels.delay"/>
								<void/>
								<label text="labels.feedback"/>

								<!-- Row 6 -->

								<label text="[" font_size="22"/>
								<value id="fbtv${i}" precision="2" width="130" font_size="22" same_line="true"/>
								<label text=":" font_size="22"/>
								<value id="fbbf${i}" read_only="true" precision="3" width="75" font_size="22" same_line="true" detailed="false"/>
								<label text="x" font_size="22"/>
								<value id="fbbm${i}" width="55" font_size="22" same_line="true"/>
								<label text="+" font_size="22"/>
								<value id="fbf${i}" read_only="true" precision="3" width="75" font_size="22" same_line="true" detailed="false"/>
								<label text="]" font_size="22"/>
								<label text="+" font_size="22"/>
								<value id="fbadd${i}" width="110" precision="3" font_size="22" same_line="true"/>

								<label text="=" font_size="22"/>

								<vbox fill="false">
									<value id="afbt${i}" width="110" precision="3" color="green" visibility="!:fbor${i}" font_size="22" same_line="true"/>
									<value id="afbt${i}" width="110" precision="3" color="red" visibility=":fbor${i}" font_size="22" same_line="true"/>
								</vbox>

								<!-- Row 7 -->

								<void/>
								<combo id="fbtr${i}" fill="false" pad_bottom="5" width="64"/>
								<void/>
								<frac id="fbbf${i}" id2="fbbd${i}" color="green"/>
								<void/>
								<knob id="fbbm${i}" size="12" scale_color="knob_scale" scale_hue_id="hue${i}"/>
								<void/>
								<frac id="fbf${i}" id2="fbd${i}" color="green"/>
								<void/>
								<void/>
								<knob id="fbadd${i}" size="12" scale_color="knob_scale" scale_hue_id="hue${i}"/>
								<void/>
								<void/>

							</grid>
						</align>

						<!-- Separator -->
						<hsep/>
						<align hpos="0" pad_bottom="8">
							<label text="labels.delay_line_processing"/>
						</align>

						<!-- Delay settings modifed -->
						<!-- Delay settings modifed -->
						<grid rows="4" cols="15" transpose="true">
							<!-- Buttons and Hue -->
							<!-- Column 1 -->
							<void/>
							<label text="labels.controls"/>
							<cell rows="2">
								<grid rows="3" cols="2">
									<button id="on${i}" led="true" color="yellow" size="12"/>
									<align hpos="0">
										<label text="labels.chan.on"/>
									</align>
									<button id="s${i}" led="true" color="green" size="12"/>
									<align hpos="0">
										<label text="labels.chan.solo"/>
									</align>
									<button id="m${i}" led="true" color="red" size="12"/>
									<align hpos="0">
										<label text="labels.chan.mute"/>
									</align>
								</grid>
							</cell>

							<!-- Column 2 -->
							<void/>

							<label text="labels.chan.hue"/>
							<knob id="hue${i}" size="20" scale_color="knob_scale" scale_hue_id="hue${i}"/>
							<value id="hue${i}" width="45" detailed="false"/>

							<!-- Column 3 -->
							<cell rows="4"><vsep/></cell>

							<!-- EQ -->
							<!-- Column 4 -->
							<cell cols="8">
								<label text="labels.equalizer"/>
							</cell>
							<label text="labels.filters"/>
							<cell rows="2">
								<grid rows="3" cols="2" spacing="4">
									<button id="lc${i}" led="true" color="magenta" size="12"/>
									<label text="labels.flt.L_owC_ut"/>
									<button id="eq${i}" led="true" color="green" size="12"/>
									<label text="labels.flt.EQ_ualizer"/>
									<button id="hc${i}" led="true" color="cyan" size="12"/>
									<label text="labels.flt.H_ighC_ut"/>
								</grid>
							</cell>

							<!-- Column 5 -->
							<label text="labels.flt.low_cut"/>
							<knob id="flc${i}" size="20" scale_color="magenta"/>
							<value id="flc${i}" width="52" same_line="true"/>

							<!-- Column 6 -->
							<label text="labels.flt.subs"/>
							<knob id="fbs${i}" size="20" scale_color="green" balance="0 db"/>
							<value id="fbs${i}" width="62" same_line="true"/>

							<!-- Column 7 -->
							<label text="labels.flt.bass"/>
							<knob id="fbb${i}" size="20" scale_color="green" balance="0 db"/>
							<value id="fbb${i}" width="62" same_line="true"/>

							<!-- Column 8 -->
							<label text="labels.flt.middle"/>
							<knob id="fbm${i}" size="20" scale_color="green" balance="0 db"/>
							<value id="fbm${i}" width="62" same_line="true"/>

							<!-- Column 9 -->
							<label text="labels.flt.presence"/>
							<knob id="fbp${i}" size="20" scale_color="green" balance="0 db"/>
							<value id="fbp${i}" width="62" same_line="true"/>

							<!-- Column 10 -->
							<label text="labels.flt.treble"/>
							<knob id="fbt${i}" size="20" scale_color="green" balance="0 db"/>
							<value id="fbt${i}" width="62" same_line="true"/>

							<!-- Column 11 -->
							<label text="labels.flt.high_cut"/>
							<knob id="fhc${i}" size="20" scale_color="cyan"/>
							<value id="fhc${i}" width="62" same_line="true"/>

							<!-- Column 12 -->
							<cell rows="4"><vsep/></cell>

							<!-- Column 13 -->
							<void/>
							<hbox>
								<button id="fbe${i}" led="true" color="knob_scale" size="12"/>
								<align hpos="0">
									<label text="labels.feedback"/>
								</align>
							</hbox>
							<knob id="fbg${i}"/>
							<value id="fbg${i}" same_line="true"/>

							<!-- Column 14 -->
							<void/>
							<label text="labels.panorama"/>
							<knob id="p${i}" balance="0"/>
							<value id="p${i}" width="49" same_line="true"/>

							<!-- Column 15 -->
							<void/>
							<label text="labels.gain"/>
							<knob id="dg${i}" scale_color="knob_scale" scale_hue_id="hue${i}"/>
							<value id="dg${i}" width="62" same_line="true"/>

						</grid>

					</vbox>
				</ui:for>
				<!-- i -->
			</cgroup>
		</vbox>
	</hbox>
</plugin>
