139 lines
3.6 KiB
XML
139 lines
3.6 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
|
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" >
|
|
<head>
|
|
<title>Antville Colorpicker</title>
|
|
|
|
<link rel="stylesheet" type="text/css" title="CSS Stylesheet" href="<% context.url %>main.css" />
|
|
|
|
<style type="text/css">
|
|
<!--
|
|
|
|
body {
|
|
background-color: #ffffff;
|
|
font-family: Verdana, Helvetica, Arial, sans-serif;
|
|
color: #000000;
|
|
}
|
|
|
|
td {
|
|
vertical-align: top;
|
|
}
|
|
|
|
.center {
|
|
text-align: right;
|
|
vertical-align: middle;
|
|
}
|
|
|
|
.widget {
|
|
background-color: #ffffff;
|
|
font: 12px verdana;
|
|
color: #000000;
|
|
}
|
|
|
|
.link {
|
|
color: <% layout.linkcolor %>;
|
|
}
|
|
|
|
.active {
|
|
color: <% layout.alinkcolor %>;
|
|
}
|
|
|
|
.visited {
|
|
color: <% layout.vlinkcolor %>;
|
|
}
|
|
|
|
.border {
|
|
border: 1px solid #eeeeee;
|
|
}
|
|
|
|
// -->
|
|
</style>
|
|
|
|
<script type="text/javascript">
|
|
<!--
|
|
<% skin name="colorpickerScripts" %>
|
|
// -->
|
|
</script>
|
|
|
|
</head>
|
|
<body onload="cp.setCurrentColors(); cp.setDropdown(); cp.setCurrentColor();">
|
|
|
|
<table border="0" cellspacing="4" cellpadding="8">
|
|
<tr>
|
|
<td width="240" class="widget" rowspan="2">
|
|
|
|
<!-- inner table, containing the color picker widget -->
|
|
<table border="0" cellspacing="5" cellpadding="0" bgcolor="#ffffff">
|
|
<tr>
|
|
<td class="widget" colspan="2" align="center">Select
|
|
<select size="1" id="dropdown" name="color" onchange="cp.setDropDownColor(this);">
|
|
|
|
<script type="text/javascript">
|
|
<!--
|
|
var cp = Antville.ColorPicker;
|
|
for (var i in cp.colorNames)
|
|
document.write('<option value="' + i + '">' + cp.colorNames[i] + '</option>');
|
|
// -->
|
|
</script>
|
|
|
|
</select> color:
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td valign="top" class="border" title="Select color">
|
|
|
|
<script type="text/javascript">
|
|
<!--
|
|
for (var i=0; i<cp.defaultPalette.length; i++) {
|
|
var color = cp.defaultPalette[i];
|
|
if (i % cp.brightness.length == 0)
|
|
document.write("<div>");
|
|
document.write('<img id="color' + i + '" style="background-color: #' + color + ';" onclick="cp.updateBrightness(this, ' + i + ');" src="' + Antville.pixel.src + '" width="' + cp.squareSize + '" height="' + cp.squareSize + '" />');
|
|
if (i % cp.brightness.length == cp.brightness.length-1)
|
|
document.write("</div>");
|
|
}
|
|
// -->
|
|
</script>
|
|
|
|
</td>
|
|
<td valign="top">
|
|
<div class="border" title="Select color brightness">
|
|
|
|
<script type="text/javascript">
|
|
<!--
|
|
for (var i=0; i<cp.brightness.length; i++)
|
|
document.write('<div><img id="bright' + i + '" onclick="cp.updatePalette(this, ' + i + ');" src="' + Antville.pixel.src + '" width="15" height="15" style="background-color: #' + cp.brightness[i][0] + ';"/></div>');
|
|
// -->
|
|
</script>
|
|
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
|
|
</table>
|
|
|
|
</td>
|
|
<td class="widget"> <!-- just a stupid spacer cell --></td>
|
|
</tr>
|
|
<tr>
|
|
<td id="demo">
|
|
<div id="titlecolor" class="storyTitle">Sample Text</div>
|
|
<div id="textcolor" class="storyText">This is a sample text containing a <a id="linkcolor" class="link">fresh (unvisited) link</a> and a
|
|
<a id="vlinkcolor" class="visited">visited link</a>. The <a id="alinkcolor" class="active">active link</a> color is the one
|
|
you'll see while pressing the mouse button on the link.</div<br />
|
|
<div id="smallcolor" class="small">Finally, some small text.</div>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="widget">
|
|
<input class="widget" style="border: none;" id="display" value="" size="10" />
|
|
</td>
|
|
<td align="right" class="widget"><button name="accept" type="button" onclick="cp.submit();" title="accept color selection">Accept</button> <button name="cancel" type="button" onclick="cp.cancel();" title="cancel color selection">Cancel</button>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
|
|
</body>
|
|
</html>
|