<?xml version="1.0" encoding="utf-8"?>
<Application>
	<AppTitle>Untitled Application</AppTitle>
	<AppShortName>MyApp</AppShortName>
	<Author>Author name</Author>
	<Version>1.0</Version>
	<DesignDeviceName>Desktop</DesignDeviceName>
	<VariablesScanned>False</VariablesScanned>
	<PageWidth>640</PageWidth>
	<PageHeight>480</PageHeight>
	<AutoSizeWidth>False</AutoSizeWidth>
	<AutoSizeHeight>False</AutoSizeHeight>
	<HideScrollbars>False</HideScrollbars>
	<ResponsiveSize>False</ResponsiveSize>
	<PublishPlatform>WebApp</PublishPlatform>
	<EmptyBuildFolder>False</EmptyBuildFolder>
	<AppIcon>C:\Users\asmat\Documents\VisualNeoWeb\Libraries\img\default-icon.png</AppIcon>
	<CustomCSS>.hue-horizontal {
  background: linear-gradient(to right, #f00 0%, #ff0 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);
  background: -webkit-linear-gradient(to right, #f00 0%, #ff0 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);
}

/*.......for range .........*/
.range{
    width: 400px;
    height: 20px;
    appearance: none;
    background: transparent;
    outline: none;
}

.range::-webkit-slider-thumb{
    appearance: none;
    width: 10px;
    height: 10px;
    background:white;
    border-radius: 50%;
    z-index:2;
    box-shadow: rgba(0, 0, 0, 0.37) 0px 1px 4px 0px;
    border:none;
}

.range::-moz-range-thumb{
    appearance: none;
    width: 10px;
    height: 10px;
    background:white;
    border-radius: 50%;
    box-sizing:border-box;
        box-shadow: rgba(0, 0, 0, 0.37) 0px 1px 4px 0px;
    border:none;
}



/*............................................*/

.flexCenter{
display:flex;
justify-content:center;
align-items:center;
}

.flexSpacebetween{display:flex;align-items:center;justify-content:space-between;}</CustomCSS>
	<LanguageCode>en</LanguageCode>
	<DisplayMode>standalone</DisplayMode>
	<ServiceWorker>Offline page</ServiceWorker>
	<ThemeColor>#000000</ThemeColor>
	<PwaScope>/</PwaScope>
	<MobileOSTypes>[AndroidOS,iOS,WindowsPhoneOS]</MobileOSTypes>
	<WindowState>normal</WindowState>
	<TitleBar>True</TitleBar>
	<Sizeable>True</Sizeable>
	<MaximizeBtn>False</MaximizeBtn>
	<MinimizeBtn>True</MinimizeBtn>
	<SystemMenu>True</SystemMenu>
	<ContextMenu>False</ContextMenu>
	<AlwaysOnTop>False</AlwaysOnTop>
	<ShowInTaskbar>True</ShowInTaskbar>
	<SingleInstance>False</SingleInstance>
	<ChromeKioskMode>False</ChromeKioskMode>
	<Components>
		<FunctionList name="Subroutines">
			<Components>
				<Function name="UpdateColor">
					<Code>var dotPos = colorDot.position(),
                red, green, blue,
                colorOpacity = 1; //break

            // The % of contribution from the color bar base color.
            var radialPercentage = Math.max(0, 1 - Math.sqrt(Math.pow(160 - dotPos.left, 2) +
                Math.pow(dotPos.top, 2)) / 100);

            // Add the radial (base) color.
            red = $App.baseColor1 * radialPercentage;
            green = $App.baseColor2 * radialPercentage;
            blue = $App.baseColor3 * radialPercentage;

            // The % of gray contribution to the color from the linear (white-to-black) gradient.
            var grayPercentage = dotPos.top / 90;

            // The linear gradient is not uniform, so divide by its slopes.
            var prevMax = 0;
            $.each([
                { start: 255, max: .25, slope: 30 },
                { start: 225, max: .5, slope: 60 },
                { start: 175, max: .75, slope: 75 },
                { start: 100, max: 1.0001, slope: 100 }
            ], function (index, slope) {
                if (grayPercentage &lt; slope.max &amp;&amp; grayPercentage &gt;= prevMax) {
                    var grayAmount = (slope.start - (grayPercentage - prevMax) /
                        (slope.max - prevMax) * slope.slope) * (1 - radialPercentage);

                    red += grayAmount;
                    green += grayAmount;
                    blue += grayAmount;
                }

                prevMax = slope.max;
            });

            // Valid RGB values only (decimals aren&apos;t accepted).
            red = Math.floor(red);
            green = Math.floor(green);
            blue = Math.floor(blue);

            // Set the picker&apos;s color.
            $(&apos;#hex&apos;).text(neo.rgbToHex(red,green,blue));
            $(&apos;#test&apos;).css(&apos;background&apos;,`rgb(${red},${green},${blue})`);</Code>
					<Params>colorDot|STRING|</Params>
					<ScriptLanguage>JavaScript</ScriptLanguage>
				</Function>
				<Function name="rangeSlider">
					<Code>var red, green, blue;
                // Determine the appropriate RGB values for this spot on the color bar.
                if (percentage &lt; 100 / 6) {
                    red = 255;
                    green = Math.floor(percentage * 255 / (100 / 6));
                    blue = 0;
                }
                else if (percentage &lt; 100 / 3) {
                    red = 255 - Math.floor((percentage - 100 / 6) * 255 / (100 / 6));
                    green = 255;
                    blue = 0;
                }
                else if (percentage &lt; 50) {
                    red = 0;
                    green = 255;
                    blue = Math.floor((percentage - 100 / 3) * 255 / (100 / 6));
                }
                else if (percentage &lt; 200 / 3) {
                    red = 0;
                    green = 255 - Math.floor((percentage - 50) * 255 / (100 / 6));
                    blue = 255;
                }
                else if (percentage &lt; 500 / 6) {
                    red = Math.floor((percentage - 200 / 3) * 255 / (100 / 6));
                    green = 0;
                    blue = 255;
                }
                else {
                    red = 255;
                    green = 0;
                    blue = 255 - Math.floor((percentage - 500 / 6) * 255 / (100 / 6));
                };
                $(&apos;#R&apos;).html(red);
                $(&apos;#G&apos;).html(green);
                $(&apos;#B&apos;).html(blue);
//.....

$App.baseColor1= red;
$App.baseColor2= green;
$App.baseColor3= blue;

//....



$(&apos;#color,#block&apos;).css(&quot;background-color&quot;, &quot;rgb(&quot; + red + &quot;, &quot; + green + &quot;, &quot; + blue + &quot;)&quot;);
// Update the color black background to match the selected color base.
$(&apos;#block&apos;).css(&quot;background&quot;, &quot;radial-gradient(circle at top right, rgb(&quot; + red + &quot;, &quot; + green +
                    &quot;, &quot; + blue + &quot;), transparent 75%),&quot; +
                    &quot;linear-gradient(white, rgb(225, 225, 255) 25%, &quot; +
                    &quot;rgb(175, 175, 175) 50%, rgb(100, 100, 100) 75%, black)&quot;);</Code>
					<Params>percentage|STRING|</Params>
					<ScriptLanguage>JavaScript</ScriptLanguage>
				</Function>
				<Function name="rgbToHex">
					<Code>return &quot;#&quot; + ((1 &lt;&lt; 24) + (r &lt;&lt; 16) + (g &lt;&lt; 8) + b).toString(16).slice(1);</Code>
					<Params>r|STRING|;g|STRING|;b|STRING|</Params>
					<ScriptLanguage>JavaScript</ScriptLanguage>
				</Function>
			</Components>
		</FunctionList>
		<LibraryList name="Libraries"/>
		<PageList name="Main">
			<Components>
				<Page id="NewPage">
					<pageenter>BEGINJS

$App.baseColor1= 0;
$App.baseColor2= 255;
$App.baseColor3= 255;

let box = document.getElementById(&apos;block&apos;);
        // Color block.
        var colorBlock = $(&quot;&lt;div&gt;&quot;, {
            css: {
                height: 90,
                width: 160
            }
        }).appendTo(box)
            .mousedown(function (event) {
                // Ignore right clicks.
                if (event.which !== 1)
                    return;

                var pos = colorBlock.offset(),
                    height = colorBlock.height(),
                    width = colorBlock.width();

                // Updates the dot position.
                function UpdatePosition(left, top) {
                    colorDot.css({
                        left: left - pos.left,
                        top: top - pos.top
                    });

                    neo.UpdateColor(colorDot);
                }

                // Event function during mouse move.
                var mouseMove = function (event) {
                    UpdatePosition(event.clientX, event.clientY);
                };

                // Event function for mouse up; ends the mousedown events.
                var mouseUp = function () {
                    colorBlock
                        .unbind(&quot;mousemove&quot;, mouseMove)
                        .unbind(&quot;mouseup&quot;, mouseUp);
                };

                // Attach events.
                colorBlock.mousemove(mouseMove).mouseup(mouseUp);

                UpdatePosition(event.clientX, event.clientY);

                // Cancel normal mouse click of the color box.
                return false;
            });

        // Color dot.
        let colorDot = $(&quot;&lt;div&gt;&quot;, {
            css: {
                position: &quot;absolute&quot;,
                height: 6,
                width: 6,
                margin: -2,
                background: &quot;rgba(255,255,255,0.7)&quot;,
                border: &quot;1px solid black&quot;,
                &quot;border-radius&quot;: 20
            }
        }).appendTo(colorBlock);

//....................
neo.rangeSlider(50);
$(&apos;#block&apos;).css(&quot;background&quot;, &quot;radial-gradient(circle at top right, rgb(&quot; + 0 + &quot;, &quot; + 255 +
                    &quot;, &quot; +255 + &quot;), transparent 75%),&quot; +
                    &quot;linear-gradient(white, rgb(225, 225, 255) 25%, &quot; +
                    &quot;rgb(175, 175, 175) 50%, rgb(100, 100, 100) 75%, black)&quot;);
ENDJS</pageenter>
					<Components>
						<Container id="Container5">
							<left>180px</left>
							<top>50px</top>
							<width>160px</width>
							<height>180px</height>
							<style>background-color:#fff;box-shadow:rgba(14, 18, 22, 0.15) 0px 5px 15px -5px</style>
							<Components>
								<Container id="block">
									<left>0px</left>
									<top>0px</top>
									<width>160px</width>
									<height>90px</height>
									<style>background-color:red;background-image:linear-gradient(to top, #000, rgba(0,0,0,0))</style>
									<align>top</align>
								</Container>
								<Container id="Container1">
									<left>10px</left>
									<top>150px</top>
									<width>140px</width>
									<height>10px</height>
									<style>background-color:#fff;overflow-x:visible;overflow-y:visible</style>
									<align>top</align>
									<margin_left>10px</margin_left>
									<margin_top>10px</margin_top>
									<margin_right>10px</margin_right>
									<css_class>hue-horizontal flexCenter</css_class>
									<html>&lt;input ontouchmove=&quot;neo.rangeSlider(this.value)&quot; class=&quot;range&quot; onmousemove=&quot;neo.rangeSlider(this.value)&quot; type=&quot;range&quot; ng-model=&quot;$root.x&quot; min=&quot;0&quot; max=&quot;100&quot; value=&quot;1&quot; &gt;</html>
								</Container>
								<Container id="hex">
									<left>10px</left>
									<top>120px</top>
									<width>140px</width>
									<height>20px</height>
									<style>color:#ACACAC;font-size:11px;background-color:#fff;border-color:#D4D4D4;border-radius:2px;border-style:solid;border-width:1px</style>
									<align>top</align>
									<margin_left>10px</margin_left>
									<margin_top>10px</margin_top>
									<css_class>flexCenter</css_class>
								</Container>
								<Container id="Container7">
									<left>10px</left>
									<top>140px</top>
									<width>140px</width>
									<height>20px</height>
									<style>color:#ACACAC;font-size:11px;background-color:#fff</style>
									<align>top</align>
									<margin_left>10px</margin_left>
									<margin_top>5px</margin_top>
									<css_class>flexCenter</css_class>
									<html>HEX</html>
								</Container>
							</Components>
						</Container>
						<Container id="color">
							<left>350px</left>
							<top>100px</top>
							<width>40px</width>
							<height>40px</height>
							<style>background-color:#fff;border-color:#E2E2E2;border-style:solid;border-width:1px</style>
						</Container>
						<Container id="test">
							<left>350px</left>
							<top>50px</top>
							<width>40px</width>
							<height>40px</height>
							<style>background-color:#fff;border-color:#E2E2E2;border-style:solid;border-width:1px</style>
						</Container>
					</Components>
				</Page>
			</Components>
		</PageList>
		<PageList name="Master">
			<Components>
				<Page id="MasterPage"/>
			</Components>
		</PageList>
		<PageList name="Dialog">
			<Components>
				<Page id="NewDialog">
					<Components>
						<DialogContainer id="DialogContainer1">
							<left>0px</left>
							<top>0px</top>
							<width>640px</width>
							<height>480px</height>
							<close_button>False</close_button>
							<kind>custom</kind>
						</DialogContainer>
					</Components>
				</Page>
			</Components>
		</PageList>
	</Components>
</Application>
