summaryrefslogtreecommitdiffstats
path: root/notFinishedCode/pChart2.1.2/examples/sandbox
diff options
context:
space:
mode:
authorgsmselftest2011-11-09 16:41:00 +0100
committergsmselftest2011-11-09 16:41:00 +0100
commit1c009430af80260d67c47652783931414989c75d (patch)
tree204540af3ff3d8e23892986ad7585080900b7463 /notFinishedCode/pChart2.1.2/examples/sandbox
parentReport relocating! (diff)
downloadgsm-selftest-1c009430af80260d67c47652783931414989c75d.tar.gz
gsm-selftest-1c009430af80260d67c47652783931414989c75d.tar.xz
gsm-selftest-1c009430af80260d67c47652783931414989c75d.zip
Final folder team project
Diffstat (limited to 'notFinishedCode/pChart2.1.2/examples/sandbox')
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.pngbin781 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.pngbin467 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.pngbin183 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.pngbin541 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.pngbin754 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.pngbin710 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.pngbin526 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.pngbin512 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.pngbin209 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.pngbin413 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.pngbin726 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.pngbin716 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.pngbin807 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.pngbin707 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.pngbin418 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.pngbin323 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.pngbin481 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gifbin2545 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.pngbin570 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.pngbin610 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gifbin66 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt61
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gifbin83 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js656
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.pngbin2684 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.pngbin2865 -> 0 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js841
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js285
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/index.php707
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php891
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php24
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/style.css89
32 files changed, 0 insertions, 3554 deletions
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.png
deleted file mode 100644
index 89c8129..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.png
deleted file mode 100644
index 807b862..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.png
deleted file mode 100644
index b084354..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.png
deleted file mode 100644
index 9051fbc..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.png
deleted file mode 100644
index df64d97..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.png
deleted file mode 100644
index 01e933a..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.png
deleted file mode 100644
index 85020f3..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.png
deleted file mode 100644
index 67de2c6..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.png
deleted file mode 100644
index 6e6e852..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.png
deleted file mode 100644
index 7bc9233..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.png
deleted file mode 100644
index 693709c..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.png
deleted file mode 100644
index ab3100b..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.png
deleted file mode 100644
index 046811e..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.png
deleted file mode 100644
index f82a886..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.png
deleted file mode 100644
index 0bd66d1..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.png
deleted file mode 100644
index 3d8207f..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.png
deleted file mode 100644
index a1291c2..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gif b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gif
deleted file mode 100644
index 1c72ebb..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gif
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.png
deleted file mode 100644
index 44ccbf8..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.png
deleted file mode 100644
index 5c8213f..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gif b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gif
deleted file mode 100644
index 246478a..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gif
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt
deleted file mode 100644
index e1451a2..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt
+++ /dev/null
@@ -1,61 +0,0 @@
-0.12345,VOID
-680001,AXIS_FORMAT_DEFAULT
-680002,AXIS_FORMAT_TIME
-680003,AXIS_FORMAT_DATE
-680004,AXIS_FORMAT_METRIC
-680005,AXIS_FORMAT_CURRENCY
-681001,AXIS_POSITION_LEFT
-681002,AXIS_POSITION_RIGHT
-682001,AXIS_X
-682002,AXIS_Y
-690001,DIRECTION_VERTICAL
-690002,DIRECTION_HORIZONTAL
-690101,SCALE_POS_LEFTRIGHT
-690102,SCALE_POS_TOPBOTTOM
-690201,SCALE_MODE_FLOATING
-690202,SCALE_MODE_START0
-690203,SCALE_MODE_ADDALL
-690204,SCALE_MODE_ADDALL_START0
-690301,SCALE_SKIP_NONE
-690302,SCALE_SKIP_SAME
-690303,SCALE_SKIP_NUMBERS
-690401,TEXT_ALIGN_TOPLEFT
-690402,TEXT_ALIGN_TOPMIDDLE
-690403,TEXT_ALIGN_TOPRIGHT
-690404,TEXT_ALIGN_MIDDLELEFT
-690405,TEXT_ALIGN_MIDDLEMIDDLE
-690406,TEXT_ALIGN_MIDDLERIGHT
-690407,TEXT_ALIGN_BOTTOMLEFT
-690408,TEXT_ALIGN_BOTTOMMIDDLE
-690409,TEXT_ALIGN_BOTTOMRIGHT
-690501,POSITION_TOP
-690502,POSITION_BOTTOM
-690601,LABEL_POS_LEFT
-690602,LABEL_POS_CENTER
-690603,LABEL_POS_RIGHT
-690604,LABEL_POS_TOP
-690605,LABEL_POS_BOTTOM
-690606,LABEL_POS_INSIDE
-690607,LABEL_POS_OUTSIDE
-690701,ORIENTATION_HORIZONTAL
-690702,ORIENTATION_VERTICAL
-690800,LEGEND_NOBORDER
-690801,LEGEND_BOX
-690802,LEGEND_ROUND
-690901,LEGEND_VERTICAL
-690902,LEGEND_HORIZONTAL
-691051,LEGEND_FAMILY_BOX
-691052,LEGEND_FAMILY_CIRCLE
-691053,LEGEND_FAMILY_LINE
-691001,DISPLAY_AUTO
-691002,DISPLAY_MANUAL
-691011,LABELING_ALL
-691012,LABELING_DIFFERENT
-691021,BOUND_MIN
-691022,BOUND_MAX
-691023,BOUND_BOTH
-691031,BOUND_LABEL_POS_TOP
-691032,BOUND_LABEL_POS_BOTTOM
-691033,BOUND_LABEL_POS_AUTO
-691041,CAPTION_LEFT_TOP
-691042,CAPTION_RIGHT_BOTTOM \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gif b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gif
deleted file mode 100644
index 0ee9c7a..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gif
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js
deleted file mode 100644
index 5eaf763..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js
+++ /dev/null
@@ -1,656 +0,0 @@
- /*
- functions.js - Sandbox JS
-
- Version : 1.1.0
- Made by : Jean-Damien POGOLOTTI
- Last Update : 18/01/11
-
- This file can be distributed under the license you can find at :
-
- http://www.pchart.net/license
-
- You can find the whole class documentation on the pChart web site.
- */
-
- Action = "Render";
-
- function toggleAuto()
- {
- if ( document.getElementById("g_autopos").checked ) { Automatic = true; } else { Automatic = false; }
- }
-
- function doLayout()
- {
- if ( !Automatic ) { return(0); }
-
- g_width = document.getElementById("g_width").value;
- g_height = document.getElementById("g_height").value;
-
- document.getElementById("g_title_x").value = g_width/2;
-
- checkEnabledAxis();
- }
-
- /* Apply curvy corners */
- function applyCorners()
- {
- settings = {tl: { radius: 10 },tr: { radius: 10 },bl: { radius: 10 },br: { radius: 10 },antiAlias: true,autoPad: true,validTags: ["div"]}
- var myBoxObject = new curvyCorners(settings, "roundedCorner");
- myBoxObject.applyCornersToAll();
- }
-
- /* Set or remove the focus */
- function setFocus(Object,Mode)
- {
- if (Mode == true)
- { Object.style.borderColor = "#808080"; }
- else
- { Object.style.borderColor = "#D0D0D0"; }
- }
-
- function highlightDIV(ID)
- {
- if ( ID == CurrentDiv ) { return(0); }
- document.getElementById("menu"+ID).style.backgroundColor = "#F4F4F4";
- }
-
- function clearDIV(ID)
- {
- if ( ID == CurrentDiv ) { return(0); }
- document.getElementById("menu"+ID).style.backgroundColor = "#EAEAEA";
- }
-
- function toggleDIV(ID)
- {
- /* reset the tab styles */
- for (i=1;i<=6;i++)
- { if ( i != ID ) { document.getElementById("menu"+i).style.backgroundColor = "#EAEAEA"; document.getElementById("menu"+i).style.borderColor = "#FEFEFE"; } }
-
- /* hide the curently displayed tab */
- if ( CurrentDiv != ID ) { document.getElementById("tab"+CurrentDiv).style.display = "none"; }
-
- document.getElementById("tab"+ID).style.display = "block";
-
- CurrentDiv = ID;
- document.getElementById("menu"+ID).style.backgroundColor = "#D0D0D0";
- document.getElementById("menu"+ID).style.borderColor = "#B0B0B0";
- }
-
- function render()
- {
- Action = "Render";
- saveToSession();
- }
-
- function code()
- {
- Action = "Code";
- saveToSession();
- }
-
- function saveToSession()
- {
- saveGeneral();
- }
-
- function saveGeneral()
- {
- document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (General)";
-
- g_width = document.getElementById("g_width").value;
- g_height = document.getElementById("g_height").value;
- g_border = document.getElementById("g_border").checked;
- g_aa = document.getElementById("g_aa").checked;
- g_shadow = document.getElementById("g_shadow").checked;
- g_transparent = document.getElementById("g_transparent").checked;
- g_autopos = document.getElementById("g_autopos").checked;
-
- g_title_enabled = document.getElementById("g_title_enabled").checked;
- g_title = document.getElementById("g_title").value;
- g_title_align = document.getElementById("g_title_align").options[document.getElementById("g_title_align").selectedIndex].value;
- g_title_x = document.getElementById("g_title_x").value;
- g_title_y = document.getElementById("g_title_y").value;
- g_title_color = document.getElementById("g_title_color").value;
- g_title_font = document.getElementById("g_title_font").options[document.getElementById("g_title_font").selectedIndex].value;
- g_title_font_size = document.getElementById("g_title_font_size").value;
- g_title_box = document.getElementById("g_title_box").checked;
-
- g_solid_enabled = document.getElementById("g_solid_enabled").checked;
- g_solid_color = document.getElementById("g_solid_color").value;
- g_solid_dashed = document.getElementById("g_solid_dashed").checked;
-
- g_gradient_enabled = document.getElementById("g_gradient_enabled").checked;
- g_gradient_start = document.getElementById("g_gradient_start").value;
- g_gradient_end = document.getElementById("g_gradient_end").value;
- g_gradient_direction = document.getElementById("g_gradient_direction").options[document.getElementById("g_gradient_direction").selectedIndex].value;
- g_gradient_alpha = document.getElementById("g_gradient_alpha").value;
-
- var reg=new RegExp("(#)", "g");
- g_title_color = g_title_color.replace(reg,"");
- g_solid_color = g_solid_color.replace(reg,"");
- g_gradient_start = g_gradient_start.replace(reg,"");
- g_gradient_end = g_gradient_end.replace(reg,"");
-
- URL = "script/session.php?g_width="+g_width+"&g_height="+g_height+"&g_border="+g_border+"&g_aa="+g_aa+"&g_shadow="+g_shadow+"&g_autopos="+g_autopos
- +"&g_title_enabled="+g_title_enabled+"&g_title="+g_title+"&g_title_align="+g_title_align+"&g_title_x="+g_title_x
- +"&g_title_y="+g_title_y+"&g_title_color="+g_title_color+"&g_title_font="+g_title_font+"&g_title_font_size="+g_title_font_size+"&g_title_box="+g_title_box
- +"&g_solid_enabled="+g_solid_enabled+"&g_solid_color="+g_solid_color+"&g_solid_dashed="+g_solid_dashed
- +"&g_gradient_enabled="+g_gradient_enabled+"&g_gradient_start="+g_gradient_start+"&g_gradient_end="+g_gradient_end
- +"&g_gradient_direction="+g_gradient_direction+"&g_gradient_alpha="+g_gradient_alpha+"&g_transparent="+g_transparent
- +"&Seed="+Math.random(100);
-
- push(URL,1);
- }
-
- function saveData()
- {
- document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Data)";
-
- d_serie1_enabled = document.getElementById("d_serie1_enabled").checked;
- d_serie2_enabled = document.getElementById("d_serie2_enabled").checked;
- d_serie3_enabled = document.getElementById("d_serie3_enabled").checked;
- d_absissa_enabled = document.getElementById("d_absissa_enabled").checked;
-
- d_serie1_name = document.getElementById("d_serie1_name").value;
- d_serie2_name = document.getElementById("d_serie2_name").value;
- d_serie3_name = document.getElementById("d_serie3_name").value;
-
- d_serie1_axis = document.getElementById("d_serie1_axis").options[document.getElementById("d_serie1_axis").selectedIndex].value;
- d_serie2_axis = document.getElementById("d_serie2_axis").options[document.getElementById("d_serie2_axis").selectedIndex].value;
- d_serie3_axis = document.getElementById("d_serie3_axis").options[document.getElementById("d_serie3_axis").selectedIndex].value;
-
- data0 = ""; data1 = ""; data2 = ""; absissa = "";
- for(i=0;i<8;i++)
- {
- data0 = data0 + "!" + document.getElementById("d_serie1_data"+i).value;
- data1 = data1 + "!" + document.getElementById("d_serie2_data"+i).value;
- data2 = data2 + "!" + document.getElementById("d_serie3_data"+i).value;
- absissa = absissa + "!" + document.getElementById("d_absissa_data"+i).value;
- }
-
- d_normalize_enabled = document.getElementById("d_normalize_enabled").checked;
-
- d_axis0_name = document.getElementById("d_axis0_name").value;
- d_axis1_name = document.getElementById("d_axis1_name").value;
- d_axis2_name = document.getElementById("d_axis2_name").value;
-
- d_axis0_unit = document.getElementById("d_axis0_unit").value;
- d_axis1_unit = document.getElementById("d_axis1_unit").value;
- d_axis2_unit = document.getElementById("d_axis2_unit").value;
-
- d_axis0_position = document.getElementById("d_axis0_position").options[document.getElementById("d_axis0_position").selectedIndex].value;
- d_axis1_position = document.getElementById("d_axis1_position").options[document.getElementById("d_axis1_position").selectedIndex].value;
- d_axis2_position = document.getElementById("d_axis2_position").options[document.getElementById("d_axis2_position").selectedIndex].value;
-
- d_axis0_format = document.getElementById("d_axis0_format").options[document.getElementById("d_axis0_format").selectedIndex].value;
- d_axis1_format = document.getElementById("d_axis1_format").options[document.getElementById("d_axis1_format").selectedIndex].value;
- d_axis2_format = document.getElementById("d_axis2_format").options[document.getElementById("d_axis2_format").selectedIndex].value;
-
- URL = "script/session.php?d_serie1_enabled="+d_serie1_enabled+"&d_serie2_enabled="+d_serie2_enabled+"&d_serie3_enabled="+d_serie3_enabled
- +"&d_absissa_enabled="+d_absissa_enabled+"&d_serie1_axis="+d_serie1_axis+"&d_serie2_axis="+d_serie2_axis+"&d_serie3_axis="+d_serie3_axis
- +"&data0="+data0+"&data1="+data1+"&data2="+data2+"&absissa="+absissa+"&d_axis0_name="+d_axis0_name+"&d_axis1_name="+d_axis1_name
- +"&d_axis2_name="+d_axis2_name+"&d_axis0_unit="+d_axis0_unit+"&d_axis1_unit="+d_axis1_unit+"&d_axis2_unit="+d_axis2_unit
- +"&d_axis0_position="+d_axis0_position+"&d_axis1_position="+d_axis1_position+"&d_axis2_position="+d_axis2_position
- +"&d_normalize_enabled="+d_normalize_enabled+"&d_serie1_name="+d_serie1_name+"&d_serie2_name="+d_serie2_name+"&d_serie3_name="+d_serie3_name
- +"&d_axis0_format="+d_axis0_format+"&d_axis1_format="+d_axis1_format+"&d_axis2_format="+d_axis2_format;
-
- push(URL,2);
- }
-
- function saveScale()
- {
- document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Scale)";
-
- s_x = document.getElementById("s_x").value;
- s_y = document.getElementById("s_y").value;
- s_width = document.getElementById("s_width").value;
- s_height = document.getElementById("s_height").value;
- s_direction = document.getElementById("s_direction").options[document.getElementById("s_direction").selectedIndex].value;
- s_arrows_enabled = document.getElementById("s_arrows_enabled").checked;
- s_mode = document.getElementById("s_mode").options[document.getElementById("s_mode").selectedIndex].value;
- s_cycle_enabled = document.getElementById("s_cycle_enabled").checked;
- s_x_margin = document.getElementById("s_x_margin").value;
- s_y_margin = document.getElementById("s_y_margin").value;
- s_automargin_enabled = document.getElementById("s_automargin_enabled").checked;
- s_font = document.getElementById("s_font").options[document.getElementById("s_font").selectedIndex].value;
- s_font_size = document.getElementById("s_font_size").value;
- s_font_color = document.getElementById("s_font_color").value;
-
- s_x_labeling = document.getElementById("s_x_labeling").options[document.getElementById("s_x_labeling").selectedIndex].value;
- s_x_skip = document.getElementById("s_x_skip").value;
- s_x_label_rotation = document.getElementById("s_x_label_rotation").value;
-
- s_grid_color = document.getElementById("s_grid_color").value;
- s_grid_alpha = document.getElementById("s_grid_alpha").value;
- s_grid_x_enabled = document.getElementById("s_grid_x_enabled").checked;
- s_grid_y_enabled = document.getElementById("s_grid_y_enabled").checked;
-
- s_ticks_color = document.getElementById("s_ticks_color").value;
- s_ticks_alpha = document.getElementById("s_ticks_alpha").value;
- s_subticks_color = document.getElementById("s_subticks_color").value;
- s_subticks_alpha = document.getElementById("s_subticks_alpha").value;
- s_subticks_enabled = document.getElementById("s_subticks_enabled").checked;
-
- URL = "script/session.php?s_x="+s_x+"&s_y="+s_y+"&s_width="+s_width+"&s_height="+s_height+"&s_direction="+s_direction
- +"&s_arrows_enabled="+s_arrows_enabled+"&s_mode="+s_mode+"&s_cycle_enabled="+s_cycle_enabled+"&s_x_margin="+s_x_margin
- +"&s_y_margin="+s_y_margin+"&s_automargin_enabled="+s_automargin_enabled+"&s_x_labeling="+s_x_labeling+"&s_x_skip="+s_x_skip
- +"&s_x_label_rotation="+s_x_label_rotation+"&s_grid_color="+s_grid_color+"&s_grid_alpha="+s_grid_alpha+"&s_grid_x_enabled="+s_grid_x_enabled
- +"&s_grid_y_enabled="+s_grid_y_enabled+"&s_ticks_color="+s_ticks_color+"&s_ticks_alpha="+s_ticks_alpha+"&s_subticks_color="+s_subticks_color
- +"&s_subticks_alpha="+s_subticks_alpha+"&s_subticks_enabled="+s_subticks_enabled+"&s_font="+s_font+"&s_font_size="+s_font_size
- +"&s_font_color="+s_font_color+"&Seed="+Math.random(100);
-
- push(URL,3);
- }
-
- function saveChart()
- {
- document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Chart)";
-
- c_family = document.getElementById("c_family").options[document.getElementById("c_family").selectedIndex].value;
- c_display_values = document.getElementById("c_display_values").checked;
- c_break_color = document.getElementById("c_break_color").value;
- c_break = document.getElementById("c_break").checked;
-
- c_plot_size = document.getElementById("c_plot_size").value;
- c_border_size = document.getElementById("c_border_size").value;
- c_border_enabled = document.getElementById("c_border_enabled").checked;
-
- c_bar_classic = document.getElementById("c_bar_classic").checked;
- c_bar_rounded = document.getElementById("c_bar_rounded").checked;
- c_bar_gradient = document.getElementById("c_bar_gradient").checked;
- c_around_zero1 = document.getElementById("c_around_zero1").checked;
-
- c_transparency = document.getElementById("c_transparency").value;
- c_forced_transparency = document.getElementById("c_forced_transparency").checked;
- c_around_zero2 = document.getElementById("c_around_zero2").checked;
-
- URL = "script/session.php?c_family="+c_family+"&c_display_values="+c_display_values+"&c_plot_size="+c_plot_size+"&c_border_size="+c_border_size+"&c_border_enabled="+c_border_enabled
- +"&c_bar_classic="+c_bar_classic+"&c_bar_rounded="+c_bar_rounded+"&c_bar_gradient="+c_bar_gradient+"&c_around_zero1="+c_around_zero1
- +"&c_transparency="+c_transparency+"&c_forced_transparency="+c_forced_transparency+"&c_around_zero2="+c_around_zero2
- +"&c_break="+c_break+"&c_break_color="+c_break_color;
-
- push(URL,4);
- }
-
- function saveLegend()
- {
- document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Legend and Thresholds)";
-
- l_enabled = document.getElementById("l_enabled").checked;
-
- l_font = document.getElementById("l_font").options[document.getElementById("l_font").selectedIndex].value;
- l_font_size = document.getElementById("l_font_size").value;
- l_font_color = document.getElementById("l_font_color").value;
-
- l_margin = document.getElementById("l_margin").value;
- l_alpha = document.getElementById("l_alpha").value;
- l_format = document.getElementById("l_format").options[document.getElementById("l_format").selectedIndex].value;
-
- l_orientation = document.getElementById("l_orientation").options[document.getElementById("l_orientation").selectedIndex].value;
- l_box_size = document.getElementById("l_box_size").value;
-
- l_position = document.getElementById("l_position").options[document.getElementById("l_position").selectedIndex].value;
- l_x = document.getElementById("l_x").value;
- l_y = document.getElementById("l_y").value;
-
- l_family = document.getElementById("l_family").options[document.getElementById("l_family").selectedIndex].value;
-
- t_enabled = document.getElementById("t_enabled").checked;
-
- t_value = document.getElementById("t_value").value;
- t_axis0 = document.getElementById("t_axis0").checked;
- t_axis1 = document.getElementById("t_axis1").checked;
- t_axis2 = document.getElementById("t_axis2").checked;
-
- t_color = document.getElementById("t_color").value;
- t_alpha = document.getElementById("t_alpha").value;
- t_ticks = document.getElementById("t_ticks").checked;
-
- t_caption = document.getElementById("t_caption").value;
- t_box = document.getElementById("t_box").checked;
- t_caption_enabled = document.getElementById("t_caption_enabled").checked;
-
- sl_enabled = document.getElementById("sl_enabled").checked;
- sl_shaded = document.getElementById("sl_shaded").checked;
- sl_caption_enabled = document.getElementById("sl_caption_enabled").checked;
- sl_caption_line = document.getElementById("sl_caption_line").checked;
-
- p_template = document.getElementById("p_template").options[document.getElementById("p_template").selectedIndex].value;
-
- if ( t_axis0 ) { t_axis = 0; }
- if ( t_axis1 ) { t_axis = 1; }
- if ( t_axis2 ) { t_axis = 2; }
-
- URL = "script/session.php?l_enabled="+l_enabled+"&l_font="+l_font+"&l_font_size="+l_font_size+"&l_font_color="+l_font_color
- +"&l_margin="+l_margin+"&l_alpha="+l_alpha+"&l_format="+l_format+"&l_orientation="+l_orientation+"&l_box_size="+l_box_size
- +"&t_enabled="+t_enabled+"&t_value="+t_value+"&t_axis="+t_axis+"&t_color="+t_color+"&t_alpha="+t_alpha+"&t_ticks="+t_ticks
- +"&t_caption="+t_caption+"&t_box="+t_box+"&t_caption_enabled="+t_caption_enabled+"&l_position="+l_position+"&l_x="+l_x+"&l_y="+l_y
- +"&p_template="+p_template+"&l_family="+l_family+"&sl_enabled="+sl_enabled+"&sl_shaded="+sl_shaded+"&sl_caption_enabled="+sl_caption_enabled
- +"&sl_caption_line="+sl_caption_line;
-
- push(URL,5);
- }
-
- function randomize()
- {
- for(i=0;i<8;i++)
- {
- document.getElementById("d_serie1_data"+i).value = Math.ceil(Math.random()*100-50);
- document.getElementById("d_serie2_data"+i).value = Math.ceil(Math.random()*100-50);
- document.getElementById("d_serie3_data"+i).value = Math.ceil(Math.random()*100-50);
- }
- }
-
- function setColors()
- {
- applyColor("g_title_color","g_title_color_show");
- applyColor("g_solid_color","g_solid_color_show");
- applyColor("g_gradient_start","g_gradient_start_show");
- applyColor("g_gradient_end","g_gradient_end_show");
- applyColor("s_font_color","s_font_color_show");
- applyColor("s_grid_color","s_grid_color_show");
- applyColor("s_ticks_color","s_ticks_color_show");
- applyColor("s_subticks_color","s_subticks_color_show");
- applyColor("l_font_color","l_font_color_show");
- applyColor("t_color","t_color_show");
- applyColor("c_break_color","c_break_color_show");
- }
-
- function applyColor(SourceID,TargetID)
- {
- color = document.getElementById(SourceID).value;
- color = color.replace("#","");
- document.getElementById(TargetID).style.backgroundColor = "#"+color;
- }
-
- function checkChartSettings()
- {
- ChartFamily = document.getElementById("c_family").options[document.getElementById("c_family").selectedIndex].value;
-
- disableItem("c_plot_size"); disableItem("c_border_size"); disableCheck("c_border_enabled");
- disableRadio("c_bar_classic"); disableRadio("c_bar_rounded"); disableRadio("c_bar_gradient"); disableCheck("c_around_zero1");
- disableItem("c_transparency"); disableCheck("c_forced_transparency"); disableCheck("c_around_zero2");
-
- if ( ChartFamily == "plot" )
- { enableItem("c_plot_size"); enableItem("c_border_size"); enableCheck("c_border_enabled"); checkPlotBorder(); }
-
- if ( ChartFamily == "bar" || ChartFamily == "sbar" )
- { enableRadio("c_bar_classic"); enableRadio("c_bar_rounded"); enableRadio("c_bar_gradient"); enableCheck("c_around_zero1"); }
-
- if ( ChartFamily == "fspline" || ChartFamily == "area" || ChartFamily == "sarea" || ChartFamily == "fstep" )
- { enableItem("c_transparency"); enableCheck("c_forced_transparency"); enableCheck("c_around_zero2"); checkAreaChart(); }
-
- if ( Automatic )
- {
- if ( ChartFamily == "sbar" || ChartFamily == "sarea" )
- document.getElementById("s_mode").value = "SCALE_MODE_ADDALL";
- else
- document.getElementById("s_mode").value = "SCALE_MODE_FLOATING";
- }
- }
-
- function checkLegend()
- {
- l_position = document.getElementById("l_position").options[document.getElementById("l_position").selectedIndex].value;
-
- if ( l_position == "Manual" )
- { enableItem("l_x"); enableItem("l_y"); }
- else
- { disableItem("l_x"); disableItem("l_y"); }
- }
-
- function checkPlotBorder()
- {
- borderEnabled = document.getElementById("c_border_enabled").checked;
- if ( borderEnabled ) { enableItem("c_border_size"); } else { disableItem("c_border_size"); }
- }
-
- function checkAreaChart()
- {
- c_forced_transparency = document.getElementById("c_forced_transparency").checked;
- if ( c_forced_transparency ) { enableItem("c_transparency"); } else { disableItem("c_transparency"); }
- }
-
- function toggleSubTicks()
- {
- if ( !document.getElementById("s_subticks_enabled").checked )
- { disableItem("s_subticks_color"); disableItem("s_subticks_alpha"); }
- else
- { enableItem("s_subticks_color"); enableItem("s_subticks_alpha"); }
- }
-
- function toggleAutoMargins()
- {
- if ( document.getElementById("s_automargin_enabled").checked )
- { disableItem("s_x_margin"); disableItem("s_y_margin"); }
- else
- { enableItem("s_x_margin"); enableItem("s_y_margin"); }
- }
-
- function checkEnabledAxis()
- {
- Serie1Enabled = document.getElementById("d_serie1_enabled").checked;
- Serie2Enabled = document.getElementById("d_serie2_enabled").checked;
- Serie3Enabled = document.getElementById("d_serie3_enabled").checked;
- Serie1Binding = document.getElementById("d_serie1_axis").options[document.getElementById("d_serie1_axis").selectedIndex].value;
- Serie2Binding = document.getElementById("d_serie2_axis").options[document.getElementById("d_serie2_axis").selectedIndex].value;
- Serie3Binding = document.getElementById("d_serie3_axis").options[document.getElementById("d_serie3_axis").selectedIndex].value;
-
- Series = 0;
- if ( Serie1Enabled ) { Series++; }
- if ( Serie2Enabled ) { Series++; }
- if ( Serie3Enabled ) { Series++; }
-
- if ( (Serie1Binding != 0 || !Serie1Enabled) && (Serie2Binding != 0 || !Serie2Enabled) && (Serie3Binding != 0 || !Serie3Enabled) )
- { disableItem("d_axis0_name"); disableItem("d_axis0_unit"); disableItem("d_axis0_position"); disableItem("d_axis0_format"); }
- else
- { enableItem("d_axis0_name"); enableItem("d_axis0_unit"); enableItem("d_axis0_position"); enableItem("d_axis0_format"); }
-
- if ( (Serie1Binding != 1 || !Serie1Enabled) && (Serie2Binding != 1 || !Serie2Enabled) && (Serie3Binding != 1 || !Serie3Enabled) )
- { disableItem("d_axis1_name"); disableItem("d_axis1_unit"); disableItem("d_axis1_position"); disableItem("d_axis1_format"); }
- else
- { enableItem("d_axis1_name"); enableItem("d_axis1_unit"); enableItem("d_axis1_position"); enableItem("d_axis1_format"); }
-
- if ( (Serie1Binding != 2 || !Serie1Enabled) && (Serie2Binding != 2 || !Serie2Enabled) && (Serie3Binding != 2 || !Serie3Enabled) )
- { disableItem("d_axis2_name"); disableItem("d_axis2_unit"); disableItem("d_axis2_position"); disableItem("d_axis2_format"); }
- else
- { enableItem("d_axis2_name"); enableItem("d_axis2_unit"); enableItem("d_axis2_position"); enableItem("d_axis2_format"); }
-
- if ( Automatic )
- {
- sl_enabled = document.getElementById("sl_enabled").checked;
- g_width = document.getElementById("g_width").value;
- g_height = document.getElementById("g_height").value;
- s_direction = document.getElementById("s_direction").options[document.getElementById("s_direction").selectedIndex].value;
-
- leftSeries = 0; rightSeries = 0;
-
- if ( !document.getElementById("d_axis0_position").disabled && document.getElementById("d_axis0_position").options[document.getElementById("d_axis0_position").selectedIndex].value == "left" ) { leftSeries++; }
- if ( !document.getElementById("d_axis0_position").disabled && document.getElementById("d_axis0_position").options[document.getElementById("d_axis0_position").selectedIndex].value == "right" ) { rightSeries++; }
- if ( !document.getElementById("d_axis1_position").disabled && document.getElementById("d_axis1_position").options[document.getElementById("d_axis1_position").selectedIndex].value == "left" ) { leftSeries++; }
- if ( !document.getElementById("d_axis1_position").disabled && document.getElementById("d_axis1_position").options[document.getElementById("d_axis1_position").selectedIndex].value == "right" ) { rightSeries++; }
- if ( !document.getElementById("d_axis2_position").disabled && document.getElementById("d_axis2_position").options[document.getElementById("d_axis2_position").selectedIndex].value == "left" ) { leftSeries++; }
- if ( !document.getElementById("d_axis2_position").disabled && document.getElementById("d_axis2_position").options[document.getElementById("d_axis2_position").selectedIndex].value == "right" ) { rightSeries++; }
-
- if ( s_direction == "SCALE_POS_LEFTRIGHT" )
- {
- if ( leftSeries == 0 ) { leftOffset = 20; } else { leftOffset = 10; }
- if ( rightSeries == 0 ) { rightOffset = 25; } else { rightOffset = 15; }
-
- leftMargin = leftOffset + 40 * leftSeries;
- width = g_width - leftMargin - 40 * rightSeries - rightOffset;
-
- if ( sl_enabled ) { BottomOffset = Series*15; } else { BottomOffset = 0; }
-
- document.getElementById("s_x").value = leftMargin;
- document.getElementById("s_y").value = 50;
- document.getElementById("s_width").value = width;
- document.getElementById("s_height").value = g_height - 50 - 40 - BottomOffset;
- }
- else
- {
- if ( leftSeries == 0 ) { topOffset = 40; } else { topOffset = 40; }
- if ( rightSeries == 0 ) { bottomOffset = 25; } else { bottomOffset = 15; }
-
- topMargin = topOffset + 30 * leftSeries;
- height = g_height - topMargin - 30 * rightSeries - bottomOffset;
-
- if ( sl_enabled ) { RightOffset = Series*15; } else { RightBottomOffset = 0; }
-
- document.getElementById("s_x").value = 70;
- document.getElementById("s_y").value = topMargin;
- document.getElementById("s_width").value = g_width - 70 - 40 - RightOffset;
- document.getElementById("s_height").value = height;
- }
- }
- }
-
- function disableItem(ID)
- {
- document.getElementById(ID).style.backgroundColor = "#E0E0E0";
- document.getElementById(ID).style.color = "#A0A0A0";
- document.getElementById(ID).disabled = true;
- }
-
- function disableCheck(ID)
- {
- document.getElementById(ID).style.color = "#A0A0A0";
- document.getElementById(ID).disabled = true;
- }
-
- function disableRadio(ID)
- {
- document.getElementById(ID).disabled = true;
- }
-
- function enableItem(ID)
- {
- document.getElementById(ID).style.backgroundColor = "#FFFFFF";
- document.getElementById(ID).style.color = "#707070";
- document.getElementById(ID).disabled = false;
- }
-
- function enableCheck(ID)
- {
- document.getElementById(ID).style.color = "#707070";
- document.getElementById(ID).disabled = false;
- }
-
- function enableRadio(ID)
- {
- document.getElementById(ID).disabled = false;
- }
-
- function setDefaultAbsissa()
- {
- document.getElementById("d_absissa_data0").value = "January";
- document.getElementById("d_absissa_data1").value = "February";
- document.getElementById("d_absissa_data2").value = "March";
- document.getElementById("d_absissa_data3").value = "April";
- document.getElementById("d_absissa_data4").value = "May";
- document.getElementById("d_absissa_data5").value = "June";
- document.getElementById("d_absissa_data6").value = "July";
- document.getElementById("d_absissa_data7").value = "August";
- }
-
- function push(URL,nextStep)
- {
- var xmlhttp=false;
- /*@cc_on @*/
- /*@if (@_jscript_version >= 5)
- try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
- @end @*/
-
- if (!xmlhttp && typeof XMLHttpRequest!='undefined')
- { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
-
- if (!xmlhttp && window.createRequest)
- { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
-
- xmlhttp.open("GET", URL,true);
-
- xmlhttp.onreadystatechange=function() {
- if (xmlhttp.readyState==4)
- {
- if ( nextStep == 1 ) { saveData(); }
- if ( nextStep == 2 ) { saveScale(); }
- if ( nextStep == 3 ) { saveChart(); }
- if ( nextStep == 4 ) { saveLegend(); }
- if ( nextStep == 5 )
- {
- if ( Action == "Render" )
- doRender();
- else
- push("script/render.php?Mode=Source&Seed="+Math.random(100),6);
- }
- if ( nextStep == 6 )
- {
- document.getElementById("result_area").innerHTML = "<pre name='code'>"+xmlhttp.responseText+"</pre>";
- }
- }
- }
- xmlhttp.send(null)
- }
-
- function doRender()
- {
- document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Rendering";
-
- RandomKey = Math.random(100);
- URL = "script/render.php?Seed=" + RandomKey;
-
- StartFade();
- }
-
- function StartFade()
- {
- Loader = new Image();
- Loader.src = URL;
- setTimeout("CheckLoadingStatus()", 200);
- }
-
- function CheckLoadingStatus()
- {
- if ( Loader.complete == true )
- {
- changeOpac(0, "result_area");
- HTMLResult = "<center><img src='" + URL + "' alt=''/></center>";
- document.getElementById("result_area").innerHTML = HTMLResult;
-
- opacity("result_area",0,100,500);
- }
- else
- setTimeout("CheckLoadingStatus()", 200);
- }
-
- function changeOpac(opacity, id)
- {
- var object = document.getElementById(id).style;
- object.opacity = (opacity / 100);
- object.MozOpacity = (opacity / 100);
- object.KhtmlOpacity = (opacity / 100);
- object.filter = "alpha(opacity=" + opacity + ")";
- }
-
- function opacity(id, opacStart, opacEnd, millisec)
- {
- var speed = Math.round(millisec / 100);
- var timer = 0;
-
- if(opacStart > opacEnd)
- {
- for(i = opacStart; i >= opacEnd; i--)
- {
- setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
- timer++;
- }
- }
- else if(opacStart < opacEnd)
- {
- for(i = opacStart; i <= opacEnd; i++)
- {
- setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
- timer++;
- }
- }
- } \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.png b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.png
deleted file mode 100644
index 3d94486..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.png b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.png
deleted file mode 100644
index 1c5e01f..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.png
+++ /dev/null
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js
deleted file mode 100644
index c2f5aae..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js
+++ /dev/null
@@ -1,841 +0,0 @@
-/**
- * jscolor, JavaScript Color Picker
- *
- * @version 1.3.1
- * @license GNU Lesser General Public License, http://www.gnu.org/copyleft/lesser.html
- * @author Jan Odvarko, http://odvarko.cz
- * @created 2008-06-15
- * @updated 2010-01-23
- * @link http://jscolor.com
- */
-
-
-var jscolor = {
-
-
- dir : '', // location of jscolor directory (leave empty to autodetect)
- bindClass : 'color', // class name
- binding : true, // automatic binding via <input class="...">
- preloading : true, // use image preloading?
-
-
- install : function() {
- jscolor.addEvent(window, 'load', jscolor.init);
- },
-
-
- init : function() {
- if(jscolor.binding) {
- jscolor.bind();
- }
- if(jscolor.preloading) {
- jscolor.preload();
- }
- },
-
-
- getDir : function() {
- if(!jscolor.dir) {
- var detected = jscolor.detectDir();
- jscolor.dir = detected!==false ? detected : 'jscolor/';
- }
- return jscolor.dir;
- },
-
-
- detectDir : function() {
- var base = location.href;
-
- var e = document.getElementsByTagName('base');
- for(var i=0; i<e.length; i+=1) {
- if(e[i].href) { base = e[i].href; }
- }
-
- var e = document.getElementsByTagName('script');
- for(var i=0; i<e.length; i+=1) {
- if(e[i].src && /(^|\/)jscolor\.js([?#].*)?$/i.test(e[i].src)) {
- var src = new jscolor.URI(e[i].src);
- var srcAbs = src.toAbsolute(base);
- srcAbs.path = srcAbs.path.replace(/[^\/]+$/, ''); // remove filename
- srcAbs.query = null;
- srcAbs.fragment = null;
- return srcAbs.toString();
- }
- }
- return false;
- },
-
-
- bind : function() {
- var matchClass = new RegExp('(^|\\s)('+jscolor.bindClass+')\\s*(\\{[^}]*\\})?', 'i');
- var e = document.getElementsByTagName('input');
- for(var i=0; i<e.length; i+=1) {
- var m;
- if(!e[i].color && e[i].className && (m = e[i].className.match(matchClass))) {
- var prop = {};
- if(m[3]) {
- try {
- eval('prop='+m[3]);
- } catch(eInvalidProp) {}
- }
- e[i].color = new jscolor.color(e[i], prop);
- }
- }
- },
-
-
- preload : function() {
- for(var fn in jscolor.imgRequire) {
- if(jscolor.imgRequire.hasOwnProperty(fn)) {
- jscolor.loadImage(fn);
- }
- }
- },
-
-
- images : {
- pad : [ 181, 101 ],
- sld : [ 16, 101 ],
- cross : [ 15, 15 ],
- arrow : [ 7, 11 ]
- },
-
-
- imgRequire : {},
- imgLoaded : {},
-
-
- requireImage : function(filename) {
- jscolor.imgRequire[filename] = true;
- },
-
-
- loadImage : function(filename) {
- if(!jscolor.imgLoaded[filename]) {
- jscolor.imgLoaded[filename] = new Image();
- jscolor.imgLoaded[filename].src = jscolor.getDir()+filename;
- }
- },
-
-
- fetchElement : function(mixed) {
- return typeof mixed === 'string' ? document.getElementById(mixed) : mixed;
- },
-
-
- addEvent : function(el, evnt, func) {
- if(el.addEventListener) {
- el.addEventListener(evnt, func, false);
- } else if(el.attachEvent) {
- el.attachEvent('on'+evnt, func);
- }
- },
-
-
- fireEvent : function(el, evnt) {
- if(!el) {
- return;
- }
- if(document.createEventObject) {
- var ev = document.createEventObject();
- el.fireEvent('on'+evnt, ev);
- } else if(document.createEvent) {
- var ev = document.createEvent('HTMLEvents');
- ev.initEvent(evnt, true, true);
- el.dispatchEvent(ev);
- } else if(el['on'+evnt]) { // alternatively use the traditional event model (IE5)
- el['on'+evnt]();
- }
- },
-
-
- getElementPos : function(e) {
- var e1=e, e2=e;
- var x=0, y=0;
- if(e1.offsetParent) {
- do {
- x += e1.offsetLeft;
- y += e1.offsetTop;
- } while(e1 = e1.offsetParent);
- }
- while((e2 = e2.parentNode) && e2.nodeName.toUpperCase() !== 'BODY') {
- x -= e2.scrollLeft;
- y -= e2.scrollTop;
- }
- return [x, y];
- },
-
-
- getElementSize : function(e) {
- return [e.offsetWidth, e.offsetHeight];
- },
-
-
- getMousePos : function(e) {
- if(!e) { e = window.event; }
- if(typeof e.pageX === 'number') {
- return [e.pageX, e.pageY];
- } else if(typeof e.clientX === 'number') {
- return [
- e.clientX + document.body.scrollLeft + document.documentElement.scrollLeft,
- e.clientY + document.body.scrollTop + document.documentElement.scrollTop
- ];
- }
- },
-
-
- getViewPos : function() {
- if(typeof window.pageYOffset === 'number') {
- return [window.pageXOffset, window.pageYOffset];
- } else if(document.body && (document.body.scrollLeft || document.body.scrollTop)) {
- return [document.body.scrollLeft, document.body.scrollTop];
- } else if(document.documentElement && (document.documentElement.scrollLeft || document.documentElement.scrollTop)) {
- return [document.documentElement.scrollLeft, document.documentElement.scrollTop];
- } else {
- return [0, 0];
- }
- },
-
-
- getViewSize : function() {
- if(typeof window.innerWidth === 'number') {
- return [window.innerWidth, window.innerHeight];
- } else if(document.body && (document.body.clientWidth || document.body.clientHeight)) {
- return [document.body.clientWidth, document.body.clientHeight];
- } else if(document.documentElement && (document.documentElement.clientWidth || document.documentElement.clientHeight)) {
- return [document.documentElement.clientWidth, document.documentElement.clientHeight];
- } else {
- return [0, 0];
- }
- },
-
-
- URI : function(uri) { // See RFC3986
-
- this.scheme = null;
- this.authority = null;
- this.path = '';
- this.query = null;
- this.fragment = null;
-
- this.parse = function(uri) {
- var m = uri.match(/^(([A-Za-z][0-9A-Za-z+.-]*)(:))?((\/\/)([^\/?#]*))?([^?#]*)((\?)([^#]*))?((#)(.*))?/);
- this.scheme = m[3] ? m[2] : null;
- this.authority = m[5] ? m[6] : null;
- this.path = m[7];
- this.query = m[9] ? m[10] : null;
- this.fragment = m[12] ? m[13] : null;
- return this;
- };
-
- this.toString = function() {
- var result = '';
- if(this.scheme !== null) { result = result + this.scheme + ':'; }
- if(this.authority !== null) { result = result + '//' + this.authority; }
- if(this.path !== null) { result = result + this.path; }
- if(this.query !== null) { result = result + '?' + this.query; }
- if(this.fragment !== null) { result = result + '#' + this.fragment; }
- return result;
- };
-
- this.toAbsolute = function(base) {
- var base = new jscolor.URI(base);
- var r = this;
- var t = new jscolor.URI;
-
- if(base.scheme === null) { return false; }
-
- if(r.scheme !== null && r.scheme.toLowerCase() === base.scheme.toLowerCase()) {
- r.scheme = null;
- }
-
- if(r.scheme !== null) {
- t.scheme = r.scheme;
- t.authority = r.authority;
- t.path = removeDotSegments(r.path);
- t.query = r.query;
- } else {
- if(r.authority !== null) {
- t.authority = r.authority;
- t.path = removeDotSegments(r.path);
- t.query = r.query;
- } else {
- if(r.path === '') { // TODO: == or === ?
- t.path = base.path;
- if(r.query !== null) {
- t.query = r.query;
- } else {
- t.query = base.query;
- }
- } else {
- if(r.path.substr(0,1) === '/') {
- t.path = removeDotSegments(r.path);
- } else {
- if(base.authority !== null && base.path === '') { // TODO: == or === ?
- t.path = '/'+r.path;
- } else {
- t.path = base.path.replace(/[^\/]+$/,'')+r.path;
- }
- t.path = removeDotSegments(t.path);
- }
- t.query = r.query;
- }
- t.authority = base.authority;
- }
- t.scheme = base.scheme;
- }
- t.fragment = r.fragment;
-
- return t;
- };
-
- function removeDotSegments(path) {
- var out = '';
- while(path) {
- if(path.substr(0,3)==='../' || path.substr(0,2)==='./') {
- path = path.replace(/^\.+/,'').substr(1);
- } else if(path.substr(0,3)==='/./' || path==='/.') {
- path = '/'+path.substr(3);
- } else if(path.substr(0,4)==='/../' || path==='/..') {
- path = '/'+path.substr(4);
- out = out.replace(/\/?[^\/]*$/, '');
- } else if(path==='.' || path==='..') {
- path = '';
- } else {
- var rm = path.match(/^\/?[^\/]*/)[0];
- path = path.substr(rm.length);
- out = out + rm;
- }
- }
- return out;
- }
-
- if(uri) {
- this.parse(uri);
- }
-
- },
-
-
- /*
- * Usage example:
- * var myColor = new jscolor.color(myInputElement)
- */
-
- color : function(target, prop) {
-
-
- this.required = true; // refuse empty values?
- this.adjust = true; // adjust value to uniform notation?
- this.hash = false; // prefix color with # symbol?
- this.caps = true; // uppercase?
- this.valueElement = target; // value holder
- this.styleElement = target; // where to reflect current color
- this.hsv = [0, 0, 1]; // read-only 0-6, 0-1, 0-1
- this.rgb = [1, 1, 1]; // read-only 0-1, 0-1, 0-1
-
- this.pickerOnfocus = true; // display picker on focus?
- this.pickerMode = 'HSV'; // HSV | HVS
- this.pickerPosition = 'bottom'; // left | right | top | bottom
- this.pickerFace = 10; // px
- this.pickerFaceColor = 'ThreeDFace'; // CSS color
- this.pickerBorder = 1; // px
- this.pickerBorderColor = 'ThreeDHighlight ThreeDShadow ThreeDShadow ThreeDHighlight'; // CSS color
- this.pickerInset = 1; // px
- this.pickerInsetColor = 'ThreeDShadow ThreeDHighlight ThreeDHighlight ThreeDShadow'; // CSS color
- this.pickerZIndex = 10000;
-
-
- for(var p in prop) {
- if(prop.hasOwnProperty(p)) {
- this[p] = prop[p];
- }
- }
-
-
- this.hidePicker = function() {
- if(isPickerOwner()) {
- removePicker();
- }
- };
-
-
- this.showPicker = function() {
- if(!isPickerOwner()) {
- var tp = jscolor.getElementPos(target); // target pos
- var ts = jscolor.getElementSize(target); // target size
- var vp = jscolor.getViewPos(); // view pos
- var vs = jscolor.getViewSize(); // view size
- var ps = [ // picker size
- 2*this.pickerBorder + 4*this.pickerInset + 2*this.pickerFace + jscolor.images.pad[0] + 2*jscolor.images.arrow[0] + jscolor.images.sld[0],
- 2*this.pickerBorder + 2*this.pickerInset + 2*this.pickerFace + jscolor.images.pad[1]
- ];
- var a, b, c;
- switch(this.pickerPosition.toLowerCase()) {
- case 'left': a=1; b=0; c=-1; break;
- case 'right':a=1; b=0; c=1; break;
- case 'top': a=0; b=1; c=-1; break;
- default: a=0; b=1; c=1; break;
- }
- var l = (ts[b]+ps[b])/2;
- var pp = [ // picker pos
- -vp[a]+tp[a]+ps[a] > vs[a] ?
- (-vp[a]+tp[a]+ts[a]/2 > vs[a]/2 && tp[a]+ts[a]-ps[a] >= 0 ? tp[a]+ts[a]-ps[a] : tp[a]) :
- tp[a],
- -vp[b]+tp[b]+ts[b]+ps[b]-l+l*c > vs[b] ?
- (-vp[b]+tp[b]+ts[b]/2 > vs[b]/2 && tp[b]+ts[b]-l-l*c >= 0 ? tp[b]+ts[b]-l-l*c : tp[b]+ts[b]-l+l*c) :
- (tp[b]+ts[b]-l+l*c >= 0 ? tp[b]+ts[b]-l+l*c : tp[b]+ts[b]-l-l*c)
- ];
- drawPicker(pp[a], pp[b]);
- }
- };
-
-
- this.importColor = function() {
- if(!valueElement) {
- this.exportColor();
- } else {
- if(!this.adjust) {
- if(!this.fromString(valueElement.value, leaveValue)) {
- styleElement.style.backgroundColor = styleElement.jscStyle.backgroundColor;
- styleElement.style.color = styleElement.jscStyle.color;
- this.exportColor(leaveValue | leaveStyle);
- }
- } else if(!this.required && /^\s*$/.test(valueElement.value)) {
- valueElement.value = '';
- styleElement.style.backgroundColor = styleElement.jscStyle.backgroundColor;
- styleElement.style.color = styleElement.jscStyle.color;
- this.exportColor(leaveValue | leaveStyle);
-
- } else if(this.fromString(valueElement.value)) {
- // OK
- } else {
- this.exportColor();
- }
- }
- };
-
-
- this.exportColor = function(flags) {
- if(!(flags & leaveValue) && valueElement) {
- var value = this.toString();
- if(this.caps) { value = value.toUpperCase(); }
- if(this.hash) { value = '#'+value; }
- valueElement.value = value;
- }
- if(!(flags & leaveStyle) && styleElement) {
-/*
- styleElement.style.backgroundColor = '#'+this.toString();
- styleElement.style.color =
- 0.213 * this.rgb[0] +
- 0.715 * this.rgb[1] +
- 0.072 * this.rgb[2]
- < 0.5 ? '#FFF' : '#000';
-*/
- }
- if(!(flags & leavePad) && isPickerOwner()) {
- redrawPad();
- }
- if(!(flags & leaveSld) && isPickerOwner()) {
- redrawSld();
- }
- };
-
-
- this.fromHSV = function(h, s, v, flags) { // null = don't change
- h<0 && (h=0) || h>6 && (h=6);
- s<0 && (s=0) || s>1 && (s=1);
- v<0 && (v=0) || v>1 && (v=1);
- this.rgb = HSV_RGB(
- h===null ? this.hsv[0] : (this.hsv[0]=h),
- s===null ? this.hsv[1] : (this.hsv[1]=s),
- v===null ? this.hsv[2] : (this.hsv[2]=v)
- );
- this.exportColor(flags);
- };
-
-
- this.fromRGB = function(r, g, b, flags) { // null = don't change
- r<0 && (r=0) || r>1 && (r=1);
- g<0 && (g=0) || g>1 && (g=1);
- b<0 && (b=0) || b>1 && (b=1);
- var hsv = RGB_HSV(
- r===null ? this.rgb[0] : (this.rgb[0]=r),
- g===null ? this.rgb[1] : (this.rgb[1]=g),
- b===null ? this.rgb[2] : (this.rgb[2]=b)
- );
- if(hsv[0] !== null) {
- this.hsv[0] = hsv[0];
- }
- if(hsv[2] !== 0) {
- this.hsv[1] = hsv[1];
- }
- this.hsv[2] = hsv[2];
- this.exportColor(flags);
- };
-
-
- this.fromString = function(hex, flags) {
- var m = hex.match(/^\W*([0-9A-F]{3}([0-9A-F]{3})?)\W*$/i);
- if(!m) {
- return false;
- } else {
- if(m[1].length === 6) { // 6-char notation
- this.fromRGB(
- parseInt(m[1].substr(0,2),16) / 255,
- parseInt(m[1].substr(2,2),16) / 255,
- parseInt(m[1].substr(4,2),16) / 255,
- flags
- );
- } else { // 3-char notation
- this.fromRGB(
- parseInt(m[1].charAt(0)+m[1].charAt(0),16) / 255,
- parseInt(m[1].charAt(1)+m[1].charAt(1),16) / 255,
- parseInt(m[1].charAt(2)+m[1].charAt(2),16) / 255,
- flags
- );
- }
- return true;
- }
- };
-
-
- this.toString = function() {
- return (
- (0x100 | Math.round(255*this.rgb[0])).toString(16).substr(1) +
- (0x100 | Math.round(255*this.rgb[1])).toString(16).substr(1) +
- (0x100 | Math.round(255*this.rgb[2])).toString(16).substr(1)
- );
- };
-
-
- function RGB_HSV(r, g, b) {
- var n = Math.min(Math.min(r,g),b);
- var v = Math.max(Math.max(r,g),b);
- var m = v - n;
- if(m === 0) { return [ null, 0, v ]; }
- var h = r===n ? 3+(b-g)/m : (g===n ? 5+(r-b)/m : 1+(g-r)/m);
- return [ h===6?0:h, m/v, v ];
- }
-
-
- function HSV_RGB(h, s, v) {
- if(h === null) { return [ v, v, v ]; }
- var i = Math.floor(h);
- var f = i%2 ? h-i : 1-(h-i);
- var m = v * (1 - s);
- var n = v * (1 - s*f);
- switch(i) {
- case 6:
- case 0: return [v,n,m];
- case 1: return [n,v,m];
- case 2: return [m,v,n];
- case 3: return [m,n,v];
- case 4: return [n,m,v];
- case 5: return [v,m,n];
- }
- }
-
-
- function removePicker() {
- delete jscolor.picker.owner;
- document.getElementsByTagName('body')[0].removeChild(jscolor.picker.boxB);
- }
-
-
- function drawPicker(x, y) {
- if(!jscolor.picker) {
- jscolor.picker = {
- box : document.createElement('div'),
- boxB : document.createElement('div'),
- pad : document.createElement('div'),
- padB : document.createElement('div'),
- padM : document.createElement('div'),
- sld : document.createElement('div'),
- sldB : document.createElement('div'),
- sldM : document.createElement('div')
- };
- for(var i=0,segSize=4; i<jscolor.images.sld[1]; i+=segSize) {
- var seg = document.createElement('div');
- seg.style.height = segSize+'px';
- seg.style.fontSize = '1px';
- seg.style.lineHeight = '0';
- jscolor.picker.sld.appendChild(seg);
- }
- jscolor.picker.sldB.appendChild(jscolor.picker.sld);
- jscolor.picker.box.appendChild(jscolor.picker.sldB);
- jscolor.picker.box.appendChild(jscolor.picker.sldM);
- jscolor.picker.padB.appendChild(jscolor.picker.pad);
- jscolor.picker.box.appendChild(jscolor.picker.padB);
- jscolor.picker.box.appendChild(jscolor.picker.padM);
- jscolor.picker.boxB.appendChild(jscolor.picker.box);
- }
-
- var p = jscolor.picker;
-
- // recompute controls positions
- posPad = [
- x+THIS.pickerBorder+THIS.pickerFace+THIS.pickerInset,
- y+THIS.pickerBorder+THIS.pickerFace+THIS.pickerInset ];
- posSld = [
- null,
- y+THIS.pickerBorder+THIS.pickerFace+THIS.pickerInset ];
-
- // controls interaction
- p.box.onmouseup =
- p.box.onmouseout = function() { target.focus(); };
- p.box.onmousedown = function() { abortBlur=true; };
- p.box.onmousemove = function(e) { holdPad && setPad(e); holdSld && setSld(e); };
- p.padM.onmouseup =
- p.padM.onmouseout = function() { if(holdPad) { holdPad=false; jscolor.fireEvent(valueElement,'change'); } };
- p.padM.onmousedown = function(e) { holdPad=true; setPad(e); };
- p.sldM.onmouseup =
- p.sldM.onmouseout = function() { if(holdSld) { holdSld=false; jscolor.fireEvent(valueElement,'change'); } };
- p.sldM.onmousedown = function(e) { holdSld=true; setSld(e); };
-
- // picker
- p.box.style.width = 4*THIS.pickerInset + 2*THIS.pickerFace + jscolor.images.pad[0] + 2*jscolor.images.arrow[0] + jscolor.images.sld[0] + 'px';
- p.box.style.height = 2*THIS.pickerInset + 2*THIS.pickerFace + jscolor.images.pad[1] + 'px';
-
- // picker border
- p.boxB.style.position = 'absolute';
- p.boxB.style.clear = 'both';
- p.boxB.style.left = x+'px';
- p.boxB.style.top = y+'px';
- p.boxB.style.zIndex = THIS.pickerZIndex;
- p.boxB.style.border = THIS.pickerBorder+'px solid';
- p.boxB.style.borderColor = THIS.pickerBorderColor;
- p.boxB.style.background = THIS.pickerFaceColor;
-
- // pad image
- p.pad.style.width = jscolor.images.pad[0]+'px';
- p.pad.style.height = jscolor.images.pad[1]+'px';
-
- // pad border
- p.padB.style.position = 'absolute';
- p.padB.style.left = THIS.pickerFace+'px';
- p.padB.style.top = THIS.pickerFace+'px';
- p.padB.style.border = THIS.pickerInset+'px solid';
- p.padB.style.borderColor = THIS.pickerInsetColor;
-
- // pad mouse area
- p.padM.style.position = 'absolute';
- p.padM.style.left = '0';
- p.padM.style.top = '0';
- p.padM.style.width = THIS.pickerFace + 2*THIS.pickerInset + jscolor.images.pad[0] + jscolor.images.arrow[0] + 'px';
- p.padM.style.height = p.box.style.height;
- p.padM.style.cursor = 'crosshair';
-
- // slider image
- p.sld.style.overflow = 'hidden';
- p.sld.style.width = jscolor.images.sld[0]+'px';
- p.sld.style.height = jscolor.images.sld[1]+'px';
-
- // slider border
- p.sldB.style.position = 'absolute';
- p.sldB.style.right = THIS.pickerFace+'px';
- p.sldB.style.top = THIS.pickerFace+'px';
- p.sldB.style.border = THIS.pickerInset+'px solid';
- p.sldB.style.borderColor = THIS.pickerInsetColor;
-
- // slider mouse area
- p.sldM.style.position = 'absolute';
- p.sldM.style.right = '0';
- p.sldM.style.top = '0';
- p.sldM.style.width = jscolor.images.sld[0] + jscolor.images.arrow[0] + THIS.pickerFace + 2*THIS.pickerInset + 'px';
- p.sldM.style.height = p.box.style.height;
- try {
- p.sldM.style.cursor = 'pointer';
- } catch(eOldIE) {
- p.sldM.style.cursor = 'hand';
- }
-
- // load images in optimal order
- switch(modeID) {
- case 0: var padImg = 'hs.png'; break;
- case 1: var padImg = 'hv.png'; break;
- }
- p.padM.style.background = "url('"+jscolor.getDir()+"cross.gif') no-repeat";
- p.sldM.style.background = "url('"+jscolor.getDir()+"arrow.gif') no-repeat";
- p.pad.style.background = "url('"+jscolor.getDir()+padImg+"') 0 0 no-repeat";
-
- // place pointers
- redrawPad();
- redrawSld();
-
- jscolor.picker.owner = THIS;
- document.getElementsByTagName('body')[0].appendChild(p.boxB);
- }
-
-
- function redrawPad() {
- // redraw the pad pointer
- switch(modeID) {
- case 0: var yComponent = 1; break;
- case 1: var yComponent = 2; break;
- }
- var x = Math.round((THIS.hsv[0]/6) * (jscolor.images.pad[0]-1));
- var y = Math.round((1-THIS.hsv[yComponent]) * (jscolor.images.pad[1]-1));
- jscolor.picker.padM.style.backgroundPosition =
- (THIS.pickerFace+THIS.pickerInset+x - Math.floor(jscolor.images.cross[0]/2)) + 'px ' +
- (THIS.pickerFace+THIS.pickerInset+y - Math.floor(jscolor.images.cross[1]/2)) + 'px';
-
- // redraw the slider image
- var seg = jscolor.picker.sld.childNodes;
-
- switch(modeID) {
- case 0:
- var rgb = HSV_RGB(THIS.hsv[0], THIS.hsv[1], 1);
- for(var i=0; i<seg.length; i+=1) {
- seg[i].style.backgroundColor = 'rgb('+
- (rgb[0]*(1-i/seg.length)*100)+'%,'+
- (rgb[1]*(1-i/seg.length)*100)+'%,'+
- (rgb[2]*(1-i/seg.length)*100)+'%)';
- }
- break;
- case 1:
- var rgb, s, c = [ THIS.hsv[2], 0, 0 ];
- var i = Math.floor(THIS.hsv[0]);
- var f = i%2 ? THIS.hsv[0]-i : 1-(THIS.hsv[0]-i);
- switch(i) {
- case 6:
- case 0: rgb=[0,1,2]; break;
- case 1: rgb=[1,0,2]; break;
- case 2: rgb=[2,0,1]; break;
- case 3: rgb=[2,1,0]; break;
- case 4: rgb=[1,2,0]; break;
- case 5: rgb=[0,2,1]; break;
- }
- for(var i=0; i<seg.length; i+=1) {
- s = 1 - 1/(seg.length-1)*i;
- c[1] = c[0] * (1 - s*f);
- c[2] = c[0] * (1 - s);
- seg[i].style.backgroundColor = 'rgb('+
- (c[rgb[0]]*100)+'%,'+
- (c[rgb[1]]*100)+'%,'+
- (c[rgb[2]]*100)+'%)';
- }
- break;
- }
- }
-
-
- function redrawSld() {
- // redraw the slider pointer
- switch(modeID) {
- case 0: var yComponent = 2; break;
- case 1: var yComponent = 1; break;
- }
- var y = Math.round((1-THIS.hsv[yComponent]) * (jscolor.images.sld[1]-1));
- jscolor.picker.sldM.style.backgroundPosition =
- '0 ' + (THIS.pickerFace+THIS.pickerInset+y - Math.floor(jscolor.images.arrow[1]/2)) + 'px';
- }
-
-
- function isPickerOwner() {
- return jscolor.picker && jscolor.picker.owner === THIS;
- }
-
-
- function blurTarget() {
- if(valueElement === target) {
- THIS.importColor();
- }
- if(THIS.pickerOnfocus) {
- THIS.hidePicker();
- }
- }
-
-
- function blurValue() {
- if(valueElement !== target) {
- THIS.importColor();
- }
- }
-
-
- function setPad(e) {
- var posM = jscolor.getMousePos(e);
- var x = posM[0]-posPad[0];
- var y = posM[1]-posPad[1];
- switch(modeID) {
- case 0: THIS.fromHSV(x*(6/(jscolor.images.pad[0]-1)), 1 - y/(jscolor.images.pad[1]-1), null, leaveSld); break;
- case 1: THIS.fromHSV(x*(6/(jscolor.images.pad[0]-1)), null, 1 - y/(jscolor.images.pad[1]-1), leaveSld); break;
- }
- }
-
-
- function setSld(e) {
- var posM = jscolor.getMousePos(e);
- var y = posM[1]-posPad[1];
- switch(modeID) {
- case 0: THIS.fromHSV(null, null, 1 - y/(jscolor.images.sld[1]-1), leavePad); break;
- case 1: THIS.fromHSV(null, 1 - y/(jscolor.images.sld[1]-1), null, leavePad); break;
- }
- }
-
-
- var THIS = this;
- var modeID = this.pickerMode.toLowerCase()==='hvs' ? 1 : 0;
- var abortBlur = false;
- var
- valueElement = jscolor.fetchElement(this.valueElement),
- styleElement = jscolor.fetchElement(this.styleElement);
- var
- holdPad = false,
- holdSld = false;
- var
- posPad,
- posSld;
- var
- leaveValue = 1<<0,
- leaveStyle = 1<<1,
- leavePad = 1<<2,
- leaveSld = 1<<3;
-
- // target
- jscolor.addEvent(target, 'focus', function() {
- if(THIS.pickerOnfocus) { THIS.showPicker(); }
- });
- jscolor.addEvent(target, 'blur', function() {
- if(!abortBlur) {
- window.setTimeout(function(){ abortBlur || blurTarget(); abortBlur=false; }, 0);
- } else {
- abortBlur = false;
- }
- });
-
- // valueElement
- if(valueElement) {
- var updateField = function() {
- THIS.fromString(valueElement.value, leaveValue);
- };
- jscolor.addEvent(valueElement, 'keyup', updateField);
- jscolor.addEvent(valueElement, 'input', updateField);
- jscolor.addEvent(valueElement, 'blur', blurValue);
- valueElement.setAttribute('autocomplete', 'off');
- }
-
- // styleElement
- if(styleElement) {
- styleElement.jscStyle = {
- backgroundColor : styleElement.style.backgroundColor,
- color : styleElement.style.color
- };
- }
-
- // require images
- switch(modeID) {
- case 0: jscolor.requireImage('hs.png'); break;
- case 1: jscolor.requireImage('hv.png'); break;
- }
- jscolor.requireImage('cross.gif');
- jscolor.requireImage('arrow.gif');
-
- this.importColor();
- }
-
-};
-
-
-jscolor.install();
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js
deleted file mode 100644
index afc3ea3..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js
+++ /dev/null
@@ -1,285 +0,0 @@
-
- /****************************************************************
- * *
- * curvyCorners *
- * ------------ *
- * *
- * This script generates rounded corners for your divs. *
- * *
- * Version 1.2.9 *
- * Copyright (c) 2006 Cameron Cooke *
- * By: Cameron Cooke and Tim Hutchison. *
- * *
- * *
- * Website: http://www.curvycorners.net *
- * Email: info@totalinfinity.com *
- * Forum: http://www.curvycorners.net/forum/ *
- * *
- * *
- * This library is free software; you can redistribute *
- * it and/or modify it under the terms of the GNU *
- * Lesser General Public License as published by the *
- * Free Software Foundation; either version 2.1 of the *
- * License, or (at your option) any later version. *
- * *
- * This library is distributed in the hope that it will *
- * be useful, but WITHOUT ANY WARRANTY; without even the *
- * implied warranty of MERCHANTABILITY or FITNESS FOR A *
- * PARTICULAR PURPOSE. See the GNU Lesser General Public *
- * License for more details. *
- * *
- * You should have received a copy of the GNU Lesser *
- * General Public License along with this library; *
- * Inc., 59 Temple Place, Suite 330, Boston, *
- * MA 02111-1307 USA *
- * *
- ****************************************************************/
-
-var isIE = navigator.userAgent.toLowerCase().indexOf("msie") > -1; var isMoz = document.implementation && document.implementation.createDocument; var isSafari = ((navigator.userAgent.toLowerCase().indexOf('safari')!=-1)&&(navigator.userAgent.toLowerCase().indexOf('mac')!=-1))?true:false; function curvyCorners()
-{ if(typeof(arguments[0]) != "object") throw newCurvyError("First parameter of curvyCorners() must be an object."); if(typeof(arguments[1]) != "object" && typeof(arguments[1]) != "string") throw newCurvyError("Second parameter of curvyCorners() must be an object or a class name."); if(typeof(arguments[1]) == "string")
-{ var startIndex = 0; var boxCol = getElementsByClass(arguments[1]);}
-else
-{ var startIndex = 1; var boxCol = arguments;}
-var curvyCornersCol = new Array(); if(arguments[0].validTags)
-var validElements = arguments[0].validTags; else
-var validElements = ["div"]; for(var i = startIndex, j = boxCol.length; i < j; i++)
-{ var currentTag = boxCol[i].tagName.toLowerCase(); if(inArray(validElements, currentTag) !== false)
-{ curvyCornersCol[curvyCornersCol.length] = new curvyObject(arguments[0], boxCol[i]);}
-}
-this.objects = curvyCornersCol; this.applyCornersToAll = function()
-{ for(var x = 0, k = this.objects.length; x < k; x++)
-{ this.objects[x].applyCorners();}
-}
-}
-function curvyObject()
-{ this.box = arguments[1]; this.settings = arguments[0]; this.topContainer = null; this.bottomContainer = null; this.masterCorners = new Array(); this.contentDIV = null; var boxHeight = get_style(this.box, "height", "height"); var boxWidth = get_style(this.box, "width", "width"); var borderWidth = get_style(this.box, "borderTopWidth", "border-top-width"); var borderColour = get_style(this.box, "borderTopColor", "border-top-color"); var boxColour = get_style(this.box, "backgroundColor", "background-color"); var backgroundImage = get_style(this.box, "backgroundImage", "background-image"); var boxPosition = get_style(this.box, "position", "position"); var boxPadding = get_style(this.box, "paddingTop", "padding-top"); this.boxHeight = parseInt(((boxHeight != "" && boxHeight != "auto" && boxHeight.indexOf("%") == -1)? boxHeight.substring(0, boxHeight.indexOf("px")) : this.box.scrollHeight)); this.boxWidth = parseInt(((boxWidth != "" && boxWidth != "auto" && boxWidth.indexOf("%") == -1)? boxWidth.substring(0, boxWidth.indexOf("px")) : this.box.scrollWidth)); this.borderWidth = parseInt(((borderWidth != "" && borderWidth.indexOf("px") !== -1)? borderWidth.slice(0, borderWidth.indexOf("px")) : 0)); this.boxColour = format_colour(boxColour); this.boxPadding = parseInt(((boxPadding != "" && boxPadding.indexOf("px") !== -1)? boxPadding.slice(0, boxPadding.indexOf("px")) : 0)); this.borderColour = format_colour(borderColour); this.borderString = this.borderWidth + "px" + " solid " + this.borderColour; this.backgroundImage = ((backgroundImage != "none")? backgroundImage : ""); this.boxContent = this.box.innerHTML; if(boxPosition != "absolute") this.box.style.position = "relative"; this.box.style.padding = "0px"; if(isIE && boxWidth == "auto" && boxHeight == "auto") this.box.style.width = "100%"; if(this.settings.autoPad == true && this.boxPadding > 0)
-this.box.innerHTML = ""; this.applyCorners = function()
-{ for(var t = 0; t < 2; t++)
-{ switch(t)
-{ case 0:
-if(this.settings.tl || this.settings.tr)
-{ var newMainContainer = document.createElement("DIV"); newMainContainer.style.width = "100%"; newMainContainer.style.fontSize = "1px"; newMainContainer.style.overflow = "hidden"; newMainContainer.style.position = "absolute"; newMainContainer.style.paddingLeft = this.borderWidth + "px"; newMainContainer.style.paddingRight = this.borderWidth + "px"; var topMaxRadius = Math.max(this.settings.tl ? this.settings.tl.radius : 0, this.settings.tr ? this.settings.tr.radius : 0); newMainContainer.style.height = topMaxRadius + "px"; newMainContainer.style.top = 0 - topMaxRadius + "px"; newMainContainer.style.left = 0 - this.borderWidth + "px"; this.topContainer = this.box.appendChild(newMainContainer);}
-break; case 1:
-if(this.settings.bl || this.settings.br)
-{ var newMainContainer = document.createElement("DIV"); newMainContainer.style.width = "100%"; newMainContainer.style.fontSize = "1px"; newMainContainer.style.overflow = "hidden"; newMainContainer.style.position = "absolute"; newMainContainer.style.paddingLeft = this.borderWidth + "px"; newMainContainer.style.paddingRight = this.borderWidth + "px"; var botMaxRadius = Math.max(this.settings.bl ? this.settings.bl.radius : 0, this.settings.br ? this.settings.br.radius : 0); newMainContainer.style.height = botMaxRadius + "px"; newMainContainer.style.bottom = 0 - botMaxRadius + "px"; newMainContainer.style.left = 0 - this.borderWidth + "px"; this.bottomContainer = this.box.appendChild(newMainContainer);}
-break;}
-}
-if(this.topContainer) this.box.style.borderTopWidth = "0px"; if(this.bottomContainer) this.box.style.borderBottomWidth = "0px"; var corners = ["tr", "tl", "br", "bl"]; for(var i in corners)
-{ if(i > -1 < 4)
-{ var cc = corners[i]; if(!this.settings[cc])
-{ if(((cc == "tr" || cc == "tl") && this.topContainer != null) || ((cc == "br" || cc == "bl") && this.bottomContainer != null))
-{ var newCorner = document.createElement("DIV"); newCorner.style.position = "relative"; newCorner.style.fontSize = "1px"; newCorner.style.overflow = "hidden"; if(this.backgroundImage == "")
-newCorner.style.backgroundColor = this.boxColour; else
-newCorner.style.backgroundImage = this.backgroundImage; switch(cc)
-{ case "tl":
-newCorner.style.height = topMaxRadius - this.borderWidth + "px"; newCorner.style.marginRight = this.settings.tr.radius - (this.borderWidth*2) + "px"; newCorner.style.borderLeft = this.borderString; newCorner.style.borderTop = this.borderString; newCorner.style.left = -this.borderWidth + "px"; break; case "tr":
-newCorner.style.height = topMaxRadius - this.borderWidth + "px"; newCorner.style.marginLeft = this.settings.tl.radius - (this.borderWidth*2) + "px"; newCorner.style.borderRight = this.borderString; newCorner.style.borderTop = this.borderString; newCorner.style.backgroundPosition = "-" + (topMaxRadius + this.borderWidth) + "px 0px"; newCorner.style.left = this.borderWidth + "px"; break; case "bl":
-newCorner.style.height = botMaxRadius - this.borderWidth + "px"; newCorner.style.marginRight = this.settings.br.radius - (this.borderWidth*2) + "px"; newCorner.style.borderLeft = this.borderString; newCorner.style.borderBottom = this.borderString; newCorner.style.left = -this.borderWidth + "px"; newCorner.style.backgroundPosition = "-" + (this.borderWidth) + "px -" + (this.boxHeight + (botMaxRadius + this.borderWidth)) + "px"; break; case "br":
-newCorner.style.height = botMaxRadius - this.borderWidth + "px"; newCorner.style.marginLeft = this.settings.bl.radius - (this.borderWidth*2) + "px"; newCorner.style.borderRight = this.borderString; newCorner.style.borderBottom = this.borderString; newCorner.style.left = this.borderWidth + "px"
-newCorner.style.backgroundPosition = "-" + (botMaxRadius + this.borderWidth) + "px -" + (this.boxHeight + (botMaxRadius + this.borderWidth)) + "px"; break;}
-}
-}
-else
-{ if(this.masterCorners[this.settings[cc].radius])
-{ var newCorner = this.masterCorners[this.settings[cc].radius].cloneNode(true);}
-else
-{ var newCorner = document.createElement("DIV"); newCorner.style.height = this.settings[cc].radius + "px"; newCorner.style.width = this.settings[cc].radius + "px"; newCorner.style.position = "absolute"; newCorner.style.fontSize = "1px"; newCorner.style.overflow = "hidden"; var borderRadius = parseInt(this.settings[cc].radius - this.borderWidth); for(var intx = 0, j = this.settings[cc].radius; intx < j; intx++)
-{ if((intx +1) >= borderRadius)
-var y1 = -1; else
-var y1 = (Math.floor(Math.sqrt(Math.pow(borderRadius, 2) - Math.pow((intx+1), 2))) - 1); if(borderRadius != j)
-{ if((intx) >= borderRadius)
-var y2 = -1; else
-var y2 = Math.ceil(Math.sqrt(Math.pow(borderRadius,2) - Math.pow(intx, 2))); if((intx+1) >= j)
-var y3 = -1; else
-var y3 = (Math.floor(Math.sqrt(Math.pow(j ,2) - Math.pow((intx+1), 2))) - 1);}
-if((intx) >= j)
-var y4 = -1; else
-var y4 = Math.ceil(Math.sqrt(Math.pow(j ,2) - Math.pow(intx, 2))); if(y1 > -1) this.drawPixel(intx, 0, this.boxColour, 100, (y1+1), newCorner, -1, this.settings[cc].radius); if(borderRadius != j)
-{ for(var inty = (y1 + 1); inty < y2; inty++)
-{ if(this.settings.antiAlias)
-{ if(this.backgroundImage != "")
-{ var borderFract = (pixelFraction(intx, inty, borderRadius) * 100); if(borderFract < 30)
-{ this.drawPixel(intx, inty, this.borderColour, 100, 1, newCorner, 0, this.settings[cc].radius);}
-else
-{ this.drawPixel(intx, inty, this.borderColour, 100, 1, newCorner, -1, this.settings[cc].radius);}
-}
-else
-{ var pixelcolour = BlendColour(this.boxColour, this.borderColour, pixelFraction(intx, inty, borderRadius)); this.drawPixel(intx, inty, pixelcolour, 100, 1, newCorner, 0, this.settings[cc].radius, cc);}
-}
-}
-if(this.settings.antiAlias)
-{ if(y3 >= y2)
-{ if (y2 == -1) y2 = 0; this.drawPixel(intx, y2, this.borderColour, 100, (y3 - y2 + 1), newCorner, 0, 0);}
-}
-else
-{ if(y3 >= y1)
-{ this.drawPixel(intx, (y1 + 1), this.borderColour, 100, (y3 - y1), newCorner, 0, 0);}
-}
-var outsideColour = this.borderColour;}
-else
-{ var outsideColour = this.boxColour; var y3 = y1;}
-if(this.settings.antiAlias)
-{ for(var inty = (y3 + 1); inty < y4; inty++)
-{ this.drawPixel(intx, inty, outsideColour, (pixelFraction(intx, inty , j) * 100), 1, newCorner, ((this.borderWidth > 0)? 0 : -1), this.settings[cc].radius);}
-}
-}
-this.masterCorners[this.settings[cc].radius] = newCorner.cloneNode(true);}
-if(cc != "br")
-{ for(var t = 0, k = newCorner.childNodes.length; t < k; t++)
-{ var pixelBar = newCorner.childNodes[t]; var pixelBarTop = parseInt(pixelBar.style.top.substring(0, pixelBar.style.top.indexOf("px"))); var pixelBarLeft = parseInt(pixelBar.style.left.substring(0, pixelBar.style.left.indexOf("px"))); var pixelBarHeight = parseInt(pixelBar.style.height.substring(0, pixelBar.style.height.indexOf("px"))); if(cc == "tl" || cc == "bl"){ pixelBar.style.left = this.settings[cc].radius -pixelBarLeft -1 + "px";}
-if(cc == "tr" || cc == "tl"){ pixelBar.style.top = this.settings[cc].radius -pixelBarHeight -pixelBarTop + "px";}
-switch(cc)
-{ case "tr":
-pixelBar.style.backgroundPosition = "-" + Math.abs((this.boxWidth - this.settings[cc].radius + this.borderWidth) + pixelBarLeft) + "px -" + Math.abs(this.settings[cc].radius -pixelBarHeight -pixelBarTop - this.borderWidth) + "px"; break; case "tl":
-pixelBar.style.backgroundPosition = "-" + Math.abs((this.settings[cc].radius -pixelBarLeft -1) - this.borderWidth) + "px -" + Math.abs(this.settings[cc].radius -pixelBarHeight -pixelBarTop - this.borderWidth) + "px"; break; case "bl":
-pixelBar.style.backgroundPosition = "-" + Math.abs((this.settings[cc].radius -pixelBarLeft -1) - this.borderWidth) + "px -" + Math.abs((this.boxHeight + this.settings[cc].radius + pixelBarTop) -this.borderWidth) + "px"; break;}
-}
-}
-}
-if(newCorner)
-{ switch(cc)
-{ case "tl":
-if(newCorner.style.position == "absolute") newCorner.style.top = "0px"; if(newCorner.style.position == "absolute") newCorner.style.left = "0px"; if(this.topContainer) this.topContainer.appendChild(newCorner); break; case "tr":
-if(newCorner.style.position == "absolute") newCorner.style.top = "0px"; if(newCorner.style.position == "absolute") newCorner.style.right = "0px"; if(this.topContainer) this.topContainer.appendChild(newCorner); break; case "bl":
-if(newCorner.style.position == "absolute") newCorner.style.bottom = "0px"; if(newCorner.style.position == "absolute") newCorner.style.left = "0px"; if(this.bottomContainer) this.bottomContainer.appendChild(newCorner); break; case "br":
-if(newCorner.style.position == "absolute") newCorner.style.bottom = "0px"; if(newCorner.style.position == "absolute") newCorner.style.right = "0px"; if(this.bottomContainer) this.bottomContainer.appendChild(newCorner); break;}
-}
-}
-}
-var radiusDiff = new Array(); radiusDiff["t"] = Math.abs(this.settings.tl.radius - this.settings.tr.radius)
-radiusDiff["b"] = Math.abs(this.settings.bl.radius - this.settings.br.radius); for(z in radiusDiff)
-{ if(z == "t" || z == "b")
-{ if(radiusDiff[z])
-{ var smallerCornerType = ((this.settings[z + "l"].radius < this.settings[z + "r"].radius)? z +"l" : z +"r"); var newFiller = document.createElement("DIV"); newFiller.style.height = radiusDiff[z] + "px"; newFiller.style.width = this.settings[smallerCornerType].radius+ "px"
-newFiller.style.position = "absolute"; newFiller.style.fontSize = "1px"; newFiller.style.overflow = "hidden"; newFiller.style.backgroundColor = this.boxColour; switch(smallerCornerType)
-{ case "tl":
-newFiller.style.bottom = "0px"; newFiller.style.left = "0px"; newFiller.style.borderLeft = this.borderString; this.topContainer.appendChild(newFiller); break; case "tr":
-newFiller.style.bottom = "0px"; newFiller.style.right = "0px"; newFiller.style.borderRight = this.borderString; this.topContainer.appendChild(newFiller); break; case "bl":
-newFiller.style.top = "0px"; newFiller.style.left = "0px"; newFiller.style.borderLeft = this.borderString; this.bottomContainer.appendChild(newFiller); break; case "br":
-newFiller.style.top = "0px"; newFiller.style.right = "0px"; newFiller.style.borderRight = this.borderString; this.bottomContainer.appendChild(newFiller); break;}
-}
-var newFillerBar = document.createElement("DIV"); newFillerBar.style.position = "relative"; newFillerBar.style.fontSize = "1px"; newFillerBar.style.overflow = "hidden"; newFillerBar.style.backgroundColor = this.boxColour; newFillerBar.style.backgroundImage = this.backgroundImage; switch(z)
-{ case "t":
-if(this.topContainer)
-{ if(this.settings.tl.radius && this.settings.tr.radius)
-{ newFillerBar.style.height = topMaxRadius - this.borderWidth + "px"; newFillerBar.style.marginLeft = this.settings.tl.radius - this.borderWidth + "px"; newFillerBar.style.marginRight = this.settings.tr.radius - this.borderWidth + "px"; newFillerBar.style.borderTop = this.borderString; if(this.backgroundImage != "")
-newFillerBar.style.backgroundPosition = "-" + (topMaxRadius + this.borderWidth) + "px 0px"; this.topContainer.appendChild(newFillerBar);}
-this.box.style.backgroundPosition = "0px -" + (topMaxRadius - this.borderWidth) + "px";}
-break; case "b":
-if(this.bottomContainer)
-{ if(this.settings.bl.radius && this.settings.br.radius)
-{ newFillerBar.style.height = botMaxRadius - this.borderWidth + "px"; newFillerBar.style.marginLeft = this.settings.bl.radius - this.borderWidth + "px"; newFillerBar.style.marginRight = this.settings.br.radius - this.borderWidth + "px"; newFillerBar.style.borderBottom = this.borderString; if(this.backgroundImage != "")
-newFillerBar.style.backgroundPosition = "-" + (botMaxRadius + this.borderWidth) + "px -" + (this.boxHeight + (topMaxRadius + this.borderWidth)) + "px"; this.bottomContainer.appendChild(newFillerBar);}
-}
-break;}
-}
-}
-if(this.settings.autoPad == true && this.boxPadding > 0)
-{ var contentContainer = document.createElement("DIV"); contentContainer.style.position = "relative"; contentContainer.innerHTML = this.boxContent; contentContainer.className = "autoPadDiv"; var topPadding = Math.abs(topMaxRadius - this.boxPadding); var botPadding = Math.abs(botMaxRadius - this.boxPadding); if(topMaxRadius < this.boxPadding)
-contentContainer.style.paddingTop = topPadding + "px"; if(botMaxRadius < this.boxPadding)
-contentContainer.style.paddingBottom = botMaxRadius + "px"; contentContainer.style.paddingLeft = this.boxPadding + "px"; contentContainer.style.paddingRight = this.boxPadding + "px"; this.contentDIV = this.box.appendChild(contentContainer);}
-}
-this.drawPixel = function(intx, inty, colour, transAmount, height, newCorner, image, cornerRadius)
-{ var pixel = document.createElement("DIV"); pixel.style.height = height + "px"; pixel.style.width = "1px"; pixel.style.position = "absolute"; pixel.style.fontSize = "1px"; pixel.style.overflow = "hidden"; var topMaxRadius = Math.max(this.settings["tr"].radius, this.settings["tl"].radius); if(image == -1 && this.backgroundImage != "")
-{ pixel.style.backgroundImage = this.backgroundImage; pixel.style.backgroundPosition = "-" + (this.boxWidth - (cornerRadius - intx) + this.borderWidth) + "px -" + ((this.boxHeight + topMaxRadius + inty) -this.borderWidth) + "px";}
-else
-{ pixel.style.backgroundColor = colour;}
-if (transAmount != 100)
-setOpacity(pixel, transAmount); pixel.style.top = inty + "px"; pixel.style.left = intx + "px"; newCorner.appendChild(pixel);}
-}
-function insertAfter(parent, node, referenceNode)
-{ parent.insertBefore(node, referenceNode.nextSibling);}
-function BlendColour(Col1, Col2, Col1Fraction)
-{ var red1 = parseInt(Col1.substr(1,2),16); var green1 = parseInt(Col1.substr(3,2),16); var blue1 = parseInt(Col1.substr(5,2),16); var red2 = parseInt(Col2.substr(1,2),16); var green2 = parseInt(Col2.substr(3,2),16); var blue2 = parseInt(Col2.substr(5,2),16); if(Col1Fraction > 1 || Col1Fraction < 0) Col1Fraction = 1; var endRed = Math.round((red1 * Col1Fraction) + (red2 * (1 - Col1Fraction))); if(endRed > 255) endRed = 255; if(endRed < 0) endRed = 0; var endGreen = Math.round((green1 * Col1Fraction) + (green2 * (1 - Col1Fraction))); if(endGreen > 255) endGreen = 255; if(endGreen < 0) endGreen = 0; var endBlue = Math.round((blue1 * Col1Fraction) + (blue2 * (1 - Col1Fraction))); if(endBlue > 255) endBlue = 255; if(endBlue < 0) endBlue = 0; return "#" + IntToHex(endRed)+ IntToHex(endGreen)+ IntToHex(endBlue);}
-function IntToHex(strNum)
-{ base = strNum / 16; rem = strNum % 16; base = base - (rem / 16); baseS = MakeHex(base); remS = MakeHex(rem); return baseS + '' + remS;}
-function MakeHex(x)
-{ if((x >= 0) && (x <= 9))
-{ return x;}
-else
-{ switch(x)
-{ case 10: return "A"; case 11: return "B"; case 12: return "C"; case 13: return "D"; case 14: return "E"; case 15: return "F";}
-}
-}
-function pixelFraction(x, y, r)
-{ var pixelfraction = 0; var xvalues = new Array(1); var yvalues = new Array(1); var point = 0; var whatsides = ""; var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(x,2))); if ((intersect >= y) && (intersect < (y+1)))
-{ whatsides = "Left"; xvalues[point] = 0; yvalues[point] = intersect - y; point = point + 1;}
-var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(y+1,2))); if ((intersect >= x) && (intersect < (x+1)))
-{ whatsides = whatsides + "Top"; xvalues[point] = intersect - x; yvalues[point] = 1; point = point + 1;}
-var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(x+1,2))); if ((intersect >= y) && (intersect < (y+1)))
-{ whatsides = whatsides + "Right"; xvalues[point] = 1; yvalues[point] = intersect - y; point = point + 1;}
-var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(y,2))); if ((intersect >= x) && (intersect < (x+1)))
-{ whatsides = whatsides + "Bottom"; xvalues[point] = intersect - x; yvalues[point] = 0;}
-switch (whatsides)
-{ case "LeftRight":
-pixelfraction = Math.min(yvalues[0],yvalues[1]) + ((Math.max(yvalues[0],yvalues[1]) - Math.min(yvalues[0],yvalues[1]))/2); break; case "TopRight":
-pixelfraction = 1-(((1-xvalues[0])*(1-yvalues[1]))/2); break; case "TopBottom":
-pixelfraction = Math.min(xvalues[0],xvalues[1]) + ((Math.max(xvalues[0],xvalues[1]) - Math.min(xvalues[0],xvalues[1]))/2); break; case "LeftBottom":
-pixelfraction = (yvalues[0]*xvalues[1])/2; break; default:
-pixelfraction = 1;}
-return pixelfraction;}
-function rgb2Hex(rgbColour)
-{ try{ var rgbArray = rgb2Array(rgbColour); var red = parseInt(rgbArray[0]); var green = parseInt(rgbArray[1]); var blue = parseInt(rgbArray[2]); var hexColour = "#" + IntToHex(red) + IntToHex(green) + IntToHex(blue);}
-catch(e){ alert("There was an error converting the RGB value to Hexadecimal in function rgb2Hex");}
-return hexColour;}
-function rgb2Array(rgbColour)
-{ var rgbValues = rgbColour.substring(4, rgbColour.indexOf(")")); var rgbArray = rgbValues.split(", "); return rgbArray;}
-function setOpacity(obj, opacity)
-{ opacity = (opacity == 100)?99.999:opacity; if(isSafari && obj.tagName != "IFRAME")
-{ var rgbArray = rgb2Array(obj.style.backgroundColor); var red = parseInt(rgbArray[0]); var green = parseInt(rgbArray[1]); var blue = parseInt(rgbArray[2]); obj.style.backgroundColor = "rgba(" + red + ", " + green + ", " + blue + ", " + opacity/100 + ")";}
-else if(typeof(obj.style.opacity) != "undefined")
-{ obj.style.opacity = opacity/100;}
-else if(typeof(obj.style.MozOpacity) != "undefined")
-{ obj.style.MozOpacity = opacity/100;}
-else if(typeof(obj.style.filter) != "undefined")
-{ obj.style.filter = "alpha(opacity:" + opacity + ")";}
-else if(typeof(obj.style.KHTMLOpacity) != "undefined")
-{ obj.style.KHTMLOpacity = opacity/100;}
-}
-function inArray(array, value)
-{ for(var i = 0; i < array.length; i++){ if (array[i] === value) return i;}
-return false;}
-function inArrayKey(array, value)
-{ for(key in array){ if(key === value) return true;}
-return false;}
-function addEvent(elm, evType, fn, useCapture) { if (elm.addEventListener) { elm.addEventListener(evType, fn, useCapture); return true;}
-else if (elm.attachEvent) { var r = elm.attachEvent('on' + evType, fn); return r;}
-else { elm['on' + evType] = fn;}
-}
-function removeEvent(obj, evType, fn, useCapture){ if (obj.removeEventListener){ obj.removeEventListener(evType, fn, useCapture); return true;} else if (obj.detachEvent){ var r = obj.detachEvent("on"+evType, fn); return r;} else { alert("Handler could not be removed");}
-}
-function format_colour(colour)
-{ var returnColour = "#ffffff"; if(colour != "" && colour != "transparent")
-{ if(colour.substr(0, 3) == "rgb")
-{ returnColour = rgb2Hex(colour);}
-else if(colour.length == 4)
-{ returnColour = "#" + colour.substring(1, 2) + colour.substring(1, 2) + colour.substring(2, 3) + colour.substring(2, 3) + colour.substring(3, 4) + colour.substring(3, 4);}
-else
-{ returnColour = colour;}
-}
-return returnColour;}
-function get_style(obj, property, propertyNS)
-{ try
-{ if(obj.currentStyle)
-{ var returnVal = eval("obj.currentStyle." + property);}
-else
-{ if(isSafari && obj.style.display == "none")
-{ obj.style.display = ""; var wasHidden = true;}
-var returnVal = document.defaultView.getComputedStyle(obj, '').getPropertyValue(propertyNS); if(isSafari && wasHidden)
-{ obj.style.display = "none";}
-}
-}
-catch(e)
-{ }
-return returnVal;}
-function getElementsByClass(searchClass, node, tag)
-{ var classElements = new Array(); if(node == null)
-node = document; if(tag == null)
-tag = '*'; var els = node.getElementsByTagName(tag); var elsLen = els.length; var pattern = new RegExp("(^|\s)"+searchClass+"(\s|$)"); for (i = 0, j = 0; i < elsLen; i++)
-{ if(pattern.test(els[i].className))
-{ classElements[j] = els[i]; j++;}
-}
-return classElements;}
-function newCurvyError(errorMessage)
-{ return new Error("curvyCorners Error:\n" + errorMessage)
-}
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/index.php b/notFinishedCode/pChart2.1.2/examples/sandbox/index.php
deleted file mode 100644
index 52afeb0..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/index.php
+++ /dev/null
@@ -1,707 +0,0 @@
-<?php
- /*
- index.php - Sandbox web frontend
-
- Version : 1.1.0
- Made by : Jean-Damien POGOLOTTI
- Last Update : 18/01/11
-
- This file can be distributed under the license you can find at :
-
- http://www.pchart.net/license
-
- You can find the whole class documentation on the pChart web site.
- */
-?>
-<!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" lang="en">
-<head>
- <title>Sandbox system</title>
- <meta http-equiv='Content-Type' content='text/html; charset=utf-8'/>
- <meta name='description' content='pChart is an object oriented php charting library'/>
- <meta name='keywords' content='pchart, php chart, charting library, php charting'/>
- <link rel='stylesheet' type='text/css' href='style.css'/>
- <link rel='shortcut icon' href='images/favicon.ico'/>
- <script type='text/javascript' src='includes/rounded_corners_lite.inc.js'></script>
- <script type='text/javascript' src='includes/jscolor.js'></script>
- <script type='text/javascript' src='includes/functions.js'></script>
-</head>
-<body>
- <table style=''><tr><td>
- <table style='padding: 2px; background-color: #E0E0E0; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'>
- <div class='topMenu' id='menu1' onmouseover='highlightDIV(1);' onmouseout='clearDIV(1);' onclick='toggleDIV(1);'>
- <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
- <td class='topMenu'>&nbsp;General settings&nbsp;</td>
- </tr></table>
- </div>
- </td>
- <td class='topMenu' width='5'></td>
- <td class='topMenu'>
- <div class='topMenu' id='menu2' onmouseover='highlightDIV(2);' onmouseout='clearDIV(2);' onclick='toggleDIV(2);'>
- <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
- <td class='topMenu'>&nbsp;Data&nbsp;</td>
- </tr></table>
- </div>
- </td>
- <td class='topMenu' width='5'></td>
- <td class='topMenu'>
- <div class='topMenu' id='menu3' onmouseover='highlightDIV(3);' onmouseout='clearDIV(3);' onclick='toggleDIV(3);'>
- <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
- <td class='topMenu'>&nbsp;Scale&nbsp;</td>
- </tr></table>
- </div>
- </td>
- <td class='topMenu' width='5'></td>
- <td class='topMenu'>
- <div class='topMenu' id='menu4' onmouseover='highlightDIV(4);' onmouseout='clearDIV(4);' onclick='toggleDIV(4);'>
- <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
- <td class='topMenu'>&nbsp;Chart&nbsp;</td>
- </tr></table>
- </div>
- </td>
- <td class='topMenu' width='5'></td>
- <td class='topMenu'>
- <div class='topMenu' id='menu5' onmouseover='highlightDIV(5);' onmouseout='clearDIV(5);' onclick='toggleDIV(5);'>
- <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
- <td class='topMenu'>&nbsp;Legend, thresholds &amp; Misc&nbsp;</td>
- </tr></table>
- </div>
- </td>
- </tr></table>
- </td>
- <td width='5'></td>
- <td>
- <table style='padding: 2px; background-color: #D0D0D0; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'>
- <div class='topMenu' id='menu6' onmouseover='highlightDIV(6);' onmouseout='clearDIV(6);' onclick='code();'>
- <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'><img src='graphix/cog.png' width='16' height='16' alt=''/></td>
- <td class='topMenu'>&nbsp;Show code&nbsp;</td>
- </tr></table>
- </div>
- </td>
- <td class='topMenu' width='5'></td>
- <td class='topMenu'>
- <div class='topMenu' id='menu7' onmouseover='highlightDIV(7);' onmouseout='clearDIV(7);' onclick='render();'>
- <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
- <td class='topMenu'><img src='graphix/accept.png' width='16' height='16' alt=''/></td>
- <td class='topMenu'>&nbsp;Render picture&nbsp;</td>
- </tr></table>
- </div>
- </td>
- </tr></table>
- </td></tr></table>
-
- <table><tr><td valign='top'>
-
- <div class="roundedCorner" id='tab1' style='margin-top: 30px; margin-left: 20px; width: 350px; height: 420px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/wrench.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>General settings</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td>Width &nbsp;</td>
- <td><input type='text' id='g_width' value='700' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' onkeyup='doLayout();' /></td>
- <td>&nbsp;&nbsp; Height &nbsp;</td>
- <td><input type='text' id='g_height' value='230' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' onkeyup='doLayout();' /></td>
- <td>&nbsp;&nbsp;<input type='checkbox' id='g_transparent' /></td>
- <td>Transparent background</td>
- </tr></table>
- <table><tr>
- <td><input type='checkbox' id='g_aa' checked='checked' /></td>
- <td>Turn on antialiasing</td>
- <td>&nbsp;&nbsp;<input type='checkbox' id='g_shadow' checked='checked' /></td>
- <td>Enable shadow</td>
- <td>&nbsp;&nbsp; <input type='checkbox' id='g_border' checked='checked' /></td>
- <td>with a border</td>
- </tr></table>
- <table><tr>
- <td><input type='checkbox' id='g_autopos' checked='checked' onclick='toggleAuto();' /></td>
- <td>Automatic positioning of the elements</td>
- </tr></table>
-
- <br/>
-
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/comment.png' width='16' height='16' alt=''/></td>
- <td width='240'><b>Chart title</b></td>
- <td width='20'><input type='checkbox' id='g_title_enabled' checked='checked' /></td>
- <td width='38'>Enabled</td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='55'>Chart Title</td>
- <td><input type='text' id='g_title' value='My first pChart project' style='width: 260px;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- </tr></table>
- <table><tr>
- <td width='147'>Alignement method (<a class='smallLinkBlack' target='_new' href='http://wiki.pchart.net/doc.draw.text.html'>help</a>)</td>
- <td><select id='g_title_align'><?php listalign(); ?></select></td>
- </tr></table>
- <table><tr>
- <td width='55'>X position &nbsp;</td>
- <td><input type='text' id='g_title_x' value='350' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp; Y position &nbsp;</td>
- <td><input type='text' id='g_title_y' value='25' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp; Color &nbsp;</td>
- <td><input type='text' class='color' id='g_title_color' value='#FFFFFF' style='text-align: center; width: 60px;' onchange='applyColor("g_title_color","g_title_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='g_title_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- </tr></table>
- <table><tr>
- <td width='55'>Font name &nbsp;</td>
- <td><select id='g_title_font'><?php listfonts(); ?></select></td>
- <td>&nbsp;&nbsp; Size &nbsp;</td>
- <td><input type='text' id='g_title_font_size' value='14' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp; <input type='checkbox' id='g_title_box' /></td>
- <td>in a box</td>
- </tr></table>
-
- <br/>
-
- <table style='background-color: #E8E8E8; padding:1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/paintcan.png' width='16' height='16' alt=''/></td>
- <td width='240'><b>Solid background</b></td>
- <td width='20'><input type='checkbox' id='g_solid_enabled' checked='checked' /></td>
- <td width='38'>Enabled</td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='55'>Color</td>
- <td><input type='text' class='color' id='g_solid_color' value='#AAB757' style='text-align: center; width: 60px;' onchange='applyColor("g_solid_color","g_solid_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td width='40'><div id='g_solid_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- <td width='20'><input type='checkbox' id='g_solid_dashed' checked='checked' /></td>
- <td width='38'>Dashed</td>
- </tr></table>
-
- <br/>
-
- <table style='background-color: #E8E8E8; padding:1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/paintcan.png' width='16' height='16' alt=''/></td>
- <td width='240'><b>Gradient background</b></td>
- <td width='20'><input type='checkbox' id='g_gradient_enabled' checked='checked' /></td>
- <td width='38'>Enabled</td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='55'>Start color</td>
- <td><input type='text' class='color' id='g_gradient_start' value='#DBE78B' style='text-align: center; width: 60px;' onchange='applyColor("g_gradient_start","g_gradient_start_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td width='55'><div id='g_gradient_start_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- <td width='54'>End color &nbsp;</td>
- <td><input type='text' class='color' id='g_gradient_end' value='#018A44' style='text-align: center; width: 60px;' onchange='applyColor("g_gradient_end","g_gradient_end_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='g_gradient_end_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- </tr></table>
- <table><tr>
- <td width='55'>Direction</td>
- <td width='75'><select id='g_gradient_direction'><option value='vertical'>Vertical</option><option value='horizontal'>Horizontal</option></select></td>
- <td width='100'>&nbsp; Alpha transparency</td>
- <td><input type='text' id='g_gradient_alpha' value='50' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>%</td>
- </tr></table>
- </div>
-
- <div class="roundedCorner" id='tab2' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 455px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/database_table.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Dataset definition</b></td>
- </tr></table>
- <br/>
- <table>
- <tr>
- <td width='46'></td>
- <td width='65'><center>Serie 1</center></td>
- <td width='65'><center>Serie 2</center></td>
- <td width='65'><center>Serie 3</center></td>
- <td width='65'><center>Absissa</center></td>
- </tr>
- <tr>
- <td>Enabled</td>
- <td><center><input type='checkbox' id='d_serie1_enabled' checked='checked' onclick='checkEnabledAxis();' /></center></td>
- <td><center><input type='checkbox' id='d_serie2_enabled' checked='checked' onclick='checkEnabledAxis();' /></center></td>
- <td><center><input type='checkbox' id='d_serie3_enabled' checked='checked' onclick='checkEnabledAxis();' /></center></td>
- <td><center><input type='checkbox' id='d_absissa_enabled' checked='checked' /></center></td>
- </tr>
- </table>
- <table>
- <tr>
- <td width='46'>Name</td>
- <td width='65'><center><input type='text' id='d_serie1_name' value='Serie 1' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td width='65'><center><input type='text' id='d_serie2_name' value='Serie 2' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td width='65'><center><input type='text' id='d_serie3_name' value='Serie 3' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td width='65'><center>-</center></td>
- </tr>
- <tr>
- <td width='46'>Binding</td>
- <td width='65'><center><select id='d_serie1_axis' style='width: 54px;' onchange='checkEnabledAxis();'><?php listaxis(); ?></select></center></td>
- <td width='65'><center><select id='d_serie2_axis' style='width: 54px;' onchange='checkEnabledAxis();'><?php listaxis(); ?></select></center></td>
- <td width='65'><center><select id='d_serie3_axis' style='width: 54px;' onchange='checkEnabledAxis();'><?php listaxis(); ?></select></center></td>
- <td width='65'><center>-</center></td>
- </tr>
-<?php
- for($i=0; $i<8;$i++)
- {
-?>
- <tr>
-<?php if ( $i == 0 ) { ?>
- <td>Data</td>
-<?php } else { ?>
- <td></td>
-<?php } ?>
- <td><center><input type='text' id='d_serie1_data<?php echo $i; ?>' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td><center><input type='text' id='d_serie2_data<?php echo $i; ?>' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td><center><input type='text' id='d_serie3_data<?php echo $i; ?>' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td><center><input type='text' id='d_absissa_data<?php echo $i; ?>' style='width: 60px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- </tr>
-<?php
- }
-?>
- </table>
- <table>
- <tr>
- <td width='50'></td>
- <td><input type='checkbox' id='d_normalize_enabled' /></td>
- <td>normalize the datasets.</td>
- <td width='10'></td>
- <td>[ <a class='smallLinkBlack' href='javascript:randomize();'>randomize</a> ]</td>
- </tr>
- </table>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/chart_bar_edit.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Axis position and units</b></td>
- </tr></table>
- <br/>
- <table>
- <tr>
- <td width='40'></td>
- <td width='90'><center><b>Axis 0</b></center></td>
- <td width='90'><center><b>Axis 1</b></center></td>
- <td width='90'><center><b>Axis 2</b></center></td>
- </tr>
- <tr>
- <td>Name</td>
- <td><center><input type='text' id='d_axis0_name' value='1st axis' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td><center><input type='text' id='d_axis1_name' value='2nd axis' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td><center><input type='text' id='d_axis2_name' value='3rd axis' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- </tr>
- <tr>
- <td>Unit</td>
- <td><center><input type='text' id='d_axis0_unit' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td><center><input type='text' id='d_axis1_unit' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- <td><center><input type='text' id='d_axis2_unit' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
- </tr>
- <tr>
- <td>Position</td>
- <td><center><select id='d_axis0_position' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxispos(); ?></select></center></td>
- <td><center><select id='d_axis1_position' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxispos(); ?></select></center></td>
- <td><center><select id='d_axis2_position' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxispos(); ?></select></center></td>
- </tr>
- <tr>
- <td>Format</td>
- <td><center><select id='d_axis0_format' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxisformat(); ?></select></center></td>
- <td><center><select id='d_axis1_format' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxisformat(); ?></select></center></td>
- <td><center><select id='d_axis2_format' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxisformat(); ?></select></center></td>
- </tr>
- </table>
- </div>
-
- <div class="roundedCorner" id='tab3' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 435px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/layout_edit.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Charting area definition</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='50'>X &nbsp;</td>
- <td><input type='text' id='s_x' value='70' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp; Y &nbsp;</td>
- <td><input type='text' id='s_y' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp; Width &nbsp;</td>
- <td><input type='text' id='s_width' value='590' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp; Height &nbsp;</td>
- <td><input type='text' id='s_height' value='140' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- </tr></table>
- <table><tr>
- <td width='50'>Direction</td>
- <td width='160'><select id='s_direction' onchange='checkEnabledAxis();'><option value='SCALE_POS_LEFTRIGHT'>SCALE_POS_LEFTRIGHT</option><option value='SCALE_POS_TOPBOTTOM'>SCALE_POS_TOPBOTTOM</option></select></td>
- <td>&nbsp;<input type='checkbox' id='s_arrows_enabled' /></td>
- <td>&nbsp;with arrows</td>
- </tr></table>
- <table><tr>
- <td width='50'>Mode</td>
- <td width='160'><select id='s_mode'><option value='SCALE_MODE_FLOATING'>SCALE_MODE_FLOATING</option><option value='SCALE_MODE_START0'>SCALE_MODE_START0</option><option value='SCALE_MODE_ADDALL'>SCALE_MODE_ADDALL</option><option value='SCALE_MODE_ADDALL_START0'>SCALE_MODE_ADDALL_START0</option></select></td>
- <td>&nbsp;<input type='checkbox' id='s_cycle_enabled' checked='checked' /></td>
- <td>&nbsp;Background</td>
- </tr></table>
- <table><tr>
- <td width='50'>X Margin</td>
- <td width='35'><input type='text' id='s_x_margin' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td width='50'>&nbsp; Y Margin</td>
- <td width='68'><input type='text' id='s_y_margin' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp;<input type='checkbox' id='s_automargin_enabled' checked='checked' onclick='toggleAutoMargins();' /></td>
- <td>&nbsp;automatic</td>
- </tr></table>
- <table><tr>
- <td width='50'>Font</td>
- <td><select id='s_font'><?php listfonts("pf_arma_five"); ?></select></td>
- <td>&nbsp; Size &nbsp;</td>
- <td><input type='text' id='s_font_size' value='6' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp; Color &nbsp;</td>
- <td><input type='text' id='s_font_color' class='color' value='#000000' style='text-align: center; width: 50px;' onchange='applyColor("s_font_color","s_font_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='s_font_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- </tr></table>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/page_edit.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>X Axis configuration</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='50'>Mode</td>
- <td><select id='s_x_labeling'><option value='LABELING_ALL'>LABELING_ALL</option><option value='LABELING_DIFFERENT'>LABELING_DIFFERENT</option></select></td>
- <td>&nbsp;&nbsp; Skip each</td>
- <td>&nbsp;<input type='text' id='s_x_skip' value='0' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;labels</td>
- </tr></table>
- <table><tr>
- <td width='50'>Rotation</td>
- <td><input type='text' id='s_x_label_rotation' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- </tr></table>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/page_edit.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Grid</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='70'>Grid color</td>
- <td><input type='text' id='s_grid_color' class='color' value='#FFFFFF' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("s_grid_color","s_grid_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='s_grid_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- <td>&nbsp; Alpha</td>
- <td>&nbsp; <input type='text' id='s_grid_alpha' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- </tr></table>
- <table><tr>
- <td width='70'>Display</td>
- <td>&nbsp;<input type='checkbox' id='s_grid_x_enabled' checked='checked' /></td>
- <td>&nbsp;X Lines</td>
- <td>&nbsp;&nbsp;&nbsp;<input type='checkbox' id='s_grid_y_enabled' checked='checked' /></td>
- <td>&nbsp;Y Lines</td>
- </tr></table>
-
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/page_edit.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Ticks</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='70'>Ticks color</td>
- <td><input type='text' id='s_ticks_color' class='color' value='#000000' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("s_ticks_color","s_ticks_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='s_ticks_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- <td>&nbsp; Alpha</td>
- <td>&nbsp; <input type='text' id='s_ticks_alpha' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- </tr></table>
- <table><tr>
- <td width='70'>Sub ticks color</td>
- <td><input type='text' id='s_subticks_color' class='color' value='#FF0000' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("s_subticks_color","s_subticks_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='s_subticks_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- <td>&nbsp; Alpha</td>
- <td>&nbsp; <input type='text' id='s_subticks_alpha' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;<input type='checkbox' id='s_subticks_enabled' checked='checked' onclick='toggleSubTicks();' /></td>
- <td>&nbsp;enabled</td>
- </tr></table>
- </div>
-
- <div class="roundedCorner" id='tab4' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 420px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/wrench.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Chart</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='60'>Chart family</td>
- <td><select id='c_family' onchange='checkChartSettings();'><?php echo listCharts(); ?></select></td>
- <td>&nbsp;Break color</td>
- <td>&nbsp;<input type='text' id='c_break_color' class='color' value='#EA371A' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("c_break_color","c_break_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='c_break_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- </tr></table>
- <table><tr>
- <td width='60'>Settings : </td>
- <td><input type='checkbox' id='c_display_values' /></td>
- <td>&nbsp;Display values</td>
- <td>&nbsp;<input type='checkbox' id='c_break' /></td>
- <td>&nbsp;Don't break on VOID</td>
- </tr></table>
- <div style='background: #D2F5C1; padding: 4px; color: #667309; margin-top: 10px;'>
- <table><tr>
- <td width='20'><img src='graphix/comment.png' width='16' height='16' alt=''/></td>
- <td>Selecting a chart layout will enable/disable chart specifics options.</td>
- </tr></table>
- </div>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/chart_line.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Plot specifics</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='60'>Plot size</td>
- <td><input type='text' id='c_plot_size' value='3' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td width='60'>&nbsp;&nbsp; Border size</td>
- <td>&nbsp;<input type='text' id='c_border_size' value='2' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;<input type='checkbox' id='c_border_enabled' checked='checked' onclick='checkPlotBorder();' /></td>
- <td>&nbsp;border enabled</td>
- </tr></table>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/chart_bar.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Bar charts specifics</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td>&nbsp;<input type='radio' id='c_bar_classic' name='c_bar_design' value='0' checked='checked' /></td>
- <td>&nbsp;Classic</td>
- <td>&nbsp;<input type='radio' id='c_bar_rounded' name='c_bar_design' value='1' /></td>
- <td>&nbsp;Rounded</td>
- <td>&nbsp;<input type='radio' id='c_bar_gradient' name='c_bar_design' value='2' /></td>
- <td>&nbsp;Gradient filling</td>
- <td>&nbsp;<input type='checkbox' id='c_around_zero1' checked='checked' /></td>
- <td>&nbsp;around zero</td>
- </tr></table>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/chart_curve.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Area charts specifics</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='100'>Forced transparency</td>
- <td><input type='text' id='c_transparency' value='50' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;<input type='checkbox' id='c_forced_transparency' checked='checked' onclick='checkAreaChart();' /></td>
- <td>&nbsp;enabled</td>
- <td>&nbsp;<input type='checkbox' id='c_around_zero2' checked='checked' /></td>
- <td>&nbsp;wrapped around zero</td>
- </tr></table>
- </div>
-
- <div class="roundedCorner" id='tab5' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 420px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/application_form.png' width='16' height='16' alt=''/></td>
- <td width='240'><b>Legend</b></td>
- <td width='20'><input type='checkbox' id='l_enabled' checked='checked' /></td>
- <td width='38'>Enabled</td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='50'>Font</td>
- <td><select id='l_font'><?php listfonts("pf_arma_five"); ?></select></td>
- <td>&nbsp; Size &nbsp;</td>
- <td><input type='text' id='l_font_size' value='6' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp; Color &nbsp;</td>
- <td><input type='text' id='l_font_color' class='color' value='#000000' style='text-align: center; width: 50px;' onchange='applyColor("l_font_color","l_font_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='l_font_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- </tr></table>
- <table><tr>
- <td width='50'>Margin</td>
- <td><input type='text' id='l_margin' value='6' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp; Alpha &nbsp;</td>
- <td><input type='text' id='l_alpha' value='30' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp; Format</td>
- <td>&nbsp; <select id='l_format'><?php echo LegendFormat(); ?></select></td>
- </tr></table>
- <table><tr>
- <td width='50'>Orientation</td>
- <td>&nbsp; <select id='l_orientation' style='width: 160px;'><option value='LEGEND_VERTICAL'>LEGEND_VERTICAL</option><option value='LEGEND_HORIZONTAL' selected='selected'>LEGEND_HORIZONTAL</option></select></td>
- <td>&nbsp; Box size &nbsp;</td>
- <td><input type='text' id='l_box_size' value='5' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- </tr></table>
- <table><tr>
- <td width='50'>Position</td>
- <td>&nbsp; <select id='l_position' style='width: 160px;' onclick='checkLegend();'><option value='CORNER_TOP_RIGHT'>CORNER_TOP_RIGHT</option><option value='CORNER_BOTTOM_RIGHT'>CORNER_BOTTOM_RIGHT</option><option value='Manual'>Manual</option></select></td>
- <td>&nbsp; X &nbsp;</td>
- <td><input type='text' id='l_x' value='10' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp; Y &nbsp;</td>
- <td><input type='text' id='l_y' value='10' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- </tr></table>
- <table><tr>
- <td width='50'>Layout</td>
- <td>&nbsp; <select id='l_family' style='width: 160px;'><option value='LEGEND_SERIE_BOX'>LEGEND_SERIE_BOX</option><option value='LEGEND_FAMILY_CIRCLE'>LEGEND_FAMILY_CIRCLE</option><option value='LEGEND_FAMILY_LINE'>LEGEND_FAMILY_LINE</option></select></td>
- </tr></table>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/vector.png' width='16' height='16' alt=''/></td>
- <td width='240'><b>Threshold</b></td>
- <td width='20'><input type='checkbox' id='t_enabled' /></td>
- <td width='38'>Enabled</td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='50'>Value</td>
- <td width='60'><input type='text' id='t_value' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;<input type='radio' id='t_axis0' name='t_axis' value='0' checked='checked' /></td>
- <td>&nbsp;Axis 0</td>
- <td>&nbsp;<input type='radio' id='t_axis1' name='t_axis' value='1' /></td>
- <td>&nbsp;Axis 1</td>
- <td>&nbsp;<input type='radio' id='t_axis2' name='t_axis' value='2' /></td>
- <td>&nbsp;Axis 2</td>
- </tr></table>
- <table><tr>
- <td width='50'>Color</td>
- <td><input type='text' id='t_color' class='color' value='#000000' style='text-align: center; width: 50px;' onchange='applyColor("t_color","t_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td><div id='t_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
- <td>&nbsp; Alpha &nbsp;</td>
- <td><input type='text' id='t_alpha' value='50' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp;&nbsp; <input type='checkbox' id='t_ticks' checked='checked' /></td>
- <td>&nbsp; ticks &nbsp;</td>
- </tr></table>
- <table><tr>
- <td width='50'>Caption</td>
- <td><input type='text' id='t_caption' value='Threshold' style='width: 50px;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
- <td>&nbsp; <input type='checkbox' id='t_box' checked='checked' /></td>
- <td>&nbsp;in a box&nbsp;</td>
- <td>&nbsp; <input type='checkbox' id='t_caption_enabled' checked='checked' /></td>
- <td>&nbsp;caption enabled &nbsp;</td>
- </tr></table>
- <br/>
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/shape_flip_vertical.png' width='16' height='16' alt=''/></td>
- <td width='240'><b>Slope chart</b></td>
- <td width='20'><input type='checkbox' id='sl_enabled' onclick='doLayout();' /></td>
- <td width='38'>Enabled</td>
- </tr></table>
- <table><tr>
- <td>&nbsp; <input type='checkbox' id='sl_shaded' checked='checked' /></td>
- <td>&nbsp;Shaded&nbsp;</td>
- <td>&nbsp; <input type='checkbox' id='sl_caption_enabled' checked='checked' /></td>
- <td>&nbsp;With caption &nbsp;</td>
- <td>&nbsp; <input type='checkbox' id='sl_caption_line' checked='checked' /></td>
- <td>&nbsp;Use line as caption &nbsp;</td>
- </tr></table>
- <br/>
-
- <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
- <td width='20'><img src='graphix/color_swatch.png' width='16' height='16' alt=''/></td>
- <td width='300'><b>Palette</b></td>
- </tr></table>
- <br/>
- <table><tr>
- <td width='50'>Template</td>
- <td>&nbsp; <select id='p_template'><?php echo listPalettes(); ?></select></td>
- </tr></table>
- </div>
- </td>
- <td width='20'></td>
- <td width='730'>
- <center><div id='result_area' style='font-size: 10px;'></div></center>
- </td>
- </tr></table>
-<script type="text/javascript">
- CurrentDiv = 1;
- URL = "";
- Automatic = true;
-
- /* Initial layout */
- toggleDIV(1);
- applyCorners();
- randomize();
- setDefaultAbsissa();
- checkEnabledAxis();
- toggleSubTicks();
- toggleAutoMargins();
- checkChartSettings();
- checkLegend();
- setColors();
-</script>
-</body>
-</html>
-<?php
- function listfonts($Default="")
- {
- echo "<option value='advent_light.ttf'>advent_light</option>";
- echo "<option value='Bedizen.ttf'>Bedizen</option>";
- if ( $Default == "" )
- { echo "<option value='Forgotte.ttf' selected='selected'>Forgotte</option>"; }
- else
- { echo "<option value='Forgotte.ttf'>Forgotte</option>"; }
- echo "<option value='GeosansLight.ttf'>GeosansLight</option>";
- if ( $Default == "pf_arma_five" )
- { echo "<option value='pf_arma_five.ttf' selected='selected'>pf_arma_five</option>"; }
- else
- { echo "<option value='pf_arma_five.ttf'>pf_arma_five</option>"; }
- echo "<option value='Silkscreen.ttf'>Silkscreen</option>";
- }
-
- function listaxis()
- {
- echo "<option value='0' selected='selected'>Axis 0</option>";
- echo "<option value='1'>Axis 1</option>";
- echo "<option value='2'>Axis 2</option>";
- }
-
- function listaxispos()
- {
- echo "<option value='left' selected='selected'>Left</option>";
- echo "<option value='right'>Right</option>";
- }
-
- function LegendFormat()
- {
- echo "<option value='LEGEND_NOBORDER' selected='selected'>LEGEND_NOBORDER</option>";
- echo "<option value='LEGEND_BOX'>LEGEND_BOX</option>";
- echo "<option value='LEGEND_ROUND'>LEGEND_ROUND</option>";
- }
-
- function listCharts()
- {
- echo "<option value='plot'>Plot chart</option>";
- echo "<option value='line'>Line chart</option>";
- echo "<option value='spline' selected='selected'>Spline chart</option>";
- echo "<option value='step'>Step chart</option>";
- echo "<option value='bar'>Bar chart</option>";
- echo "<option value='area'>Area chart</option>";
- echo "<option value='fspline'>Filled spline chart &nbsp;&nbsp;&nbsp;&nbsp;</option>";
- echo "<option value='fstep'>Filled step chart</option>";
- echo "<option value='sbar'>Stacked bar chart</option>";
- echo "<option value='sarea'>Stacked area chart</option>";
- }
-
- function listPalettes()
- {
- echo "<option value='default'>Default</option>";
- echo "<option value='autumn'>Autumn</option>";
- echo "<option value='blind'>Blind</option>";
- echo "<option value='evening'>Evening</option>";
- echo "<option value='kitchen'>Kitchen</option>";
- echo "<option value='light'>Light</option>";
- echo "<option value='navy'>Navy</option>";
- echo "<option value='shade'>Shade</option>";
- echo "<option value='spring'>Spring</option>";
- echo "<option value='shade'>Shade</option>";
- echo "<option value='summer'>Summer</option>";
- }
-
- function listalign()
- {
- echo "<option value='TEXT_ALIGN_TOPLEFT'>TEXT_ALIGN_TOPLEFT</option>";
- echo "<option value='TEXT_ALIGN_TOPMIDDLE'>TEXT_ALIGN_TOPMIDDLE</option>";
- echo "<option value='TEXT_ALIGN_TOPRIGHT'>TEXT_ALIGN_TOPRIGHT</option>";
- echo "<option value='TEXT_ALIGN_MIDDLELEFT'>TEXT_ALIGN_MIDDLELEFT</option>";
- echo "<option selected='selected' value='TEXT_ALIGN_MIDDLEMIDDLE'>TEXT_ALIGN_MIDDLEMIDDLE</option>";
- echo "<option value='TEXT_ALIGN_MIDDLERIGHT'>TEXT_ALIGN_MIDDLERIGHT</option>";
- echo "<option value='TEXT_ALIGN_BOTTOMLEFT'>TEXT_ALIGN_BOTTOMLEFT</option>";
- echo "<option value='TEXT_ALIGN_BOTTOMMIDDLE'>TEXT_ALIGN_BOTTOMMIDDLE</option>";
- echo "<option value='TEXT_ALIGN_BOTTOMRIGHT'>TEXT_ALIGN_BOTTOMRIGHT</option>";
- }
-
- function listaxisformat()
- {
- echo "<option selected='selected' value='AXIS_FORMAT_DEFAULT'>DEFAULT</option>";
- echo "<option value='AXIS_FORMAT_METRIC'>METRIC</option>";
- echo "<option value='AXIS_FORMAT_CURRENCY'>CURRENCY</option>";
- }
-?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php b/notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php
deleted file mode 100644
index d281d86..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php
+++ /dev/null
@@ -1,891 +0,0 @@
-<?php
- /*
- render.php - Sandbox rendering engine
-
- Version : 1.1.0
- Made by : Jean-Damien POGOLOTTI
- Last Update : 18/01/11
-
- This file can be distributed under the license you can find at :
-
- http://www.pchart.net/license
-
- You can find the whole class documentation on the pChart web site.
- */
-
- session_start();
-
- if ( !isset($_GET["Mode"]) ) { $Mode = "Render"; } else { $Mode = $_GET["Mode"]; }
-
- $Constants = readConstantFile();
-
- /* -- Retrieve General configuration items -------------------------------- */
- $g_width = $_SESSION["g_width"];
- $g_height = $_SESSION["g_height"];
- $g_border = $_SESSION["g_border"];
-
- $g_aa = $_SESSION["g_aa"];
- $g_shadow = $_SESSION["g_shadow"];
- $g_transparent = $_SESSION["g_transparent"];
-
- $g_title_enabled = $_SESSION["g_title_enabled"];
- $g_title = $_SESSION["g_title"];
- $g_title_align = $_SESSION["g_title_align"];
- $g_title_x = $_SESSION["g_title_x"];
- $g_title_y = $_SESSION["g_title_y"];
- $g_title_color = $_SESSION["g_title_color"];
- $g_title_font = $_SESSION["g_title_font"];
- $g_title_font_size = $_SESSION["g_title_font_size"];
- $g_title_box = $_SESSION["g_title_box"];
-
- $g_solid_enabled = $_SESSION["g_solid_enabled"];
- $g_solid_color = $_SESSION["g_solid_color"];
- $g_solid_dashed = $_SESSION["g_solid_dashed"];
-
- $g_gradient_enabled = $_SESSION["g_gradient_enabled"];
- $g_gradient_start = $_SESSION["g_gradient_start"];
- $g_gradient_end = $_SESSION["g_gradient_end"];
- $g_gradient_direction = $_SESSION["g_gradient_direction"];
- $g_gradient_alpha = $_SESSION["g_gradient_alpha"];
- /* ------------------------------------------------------------------------ */
-
- /* -- Retrieve Data configuration items ----------------------------------- */
- $d_serie1_enabled = $_SESSION["d_serie1_enabled"];
- $d_serie2_enabled = $_SESSION["d_serie2_enabled"];
- $d_serie3_enabled = $_SESSION["d_serie3_enabled"];
- $d_absissa_enabled = $_SESSION["d_absissa_enabled"];
-
- $d_serie1_name = $_SESSION["d_serie1_name"];
- $d_serie2_name = $_SESSION["d_serie2_name"];
- $d_serie3_name = $_SESSION["d_serie3_name"];
-
- $d_serie1_axis = $_SESSION["d_serie1_axis"];
- $d_serie2_axis = $_SESSION["d_serie2_axis"];
- $d_serie3_axis = $_SESSION["d_serie3_axis"];
-
- $data0 = $_SESSION["data0"];
- $data1 = $_SESSION["data1"];
- $data2 = $_SESSION["data2"];
- $absissa = $_SESSION["absissa"];
-
- $d_normalize_enabled = $_SESSION["d_normalize_enabled"];
-
- $d_axis0_name = $_SESSION["d_axis0_name"];
- $d_axis1_name = $_SESSION["d_axis1_name"];
- $d_axis2_name = $_SESSION["d_axis2_name"];
-
- $d_axis0_unit = $_SESSION["d_axis0_unit"];
- $d_axis1_unit = $_SESSION["d_axis1_unit"];
- $d_axis2_unit = $_SESSION["d_axis2_unit"];
-
- $d_axis0_position = $_SESSION["d_axis0_position"];
- $d_axis1_position = $_SESSION["d_axis1_position"];
- $d_axis2_position = $_SESSION["d_axis2_position"];
-
- $d_axis0_format = $_SESSION["d_axis0_format"];
- $d_axis1_format = $_SESSION["d_axis1_format"];
- $d_axis2_format = $_SESSION["d_axis2_format"];
-
- /* ------------------------------------------------------------------------ */
-
- /* -- Retrieve Scale configuration items ---------------------------------- */
- $s_x = $_SESSION["s_x"];
- $s_y = $_SESSION["s_y"];
- $s_width = $_SESSION["s_width"];
- $s_height = $_SESSION["s_height"];
- $s_direction = $_SESSION["s_direction"];
- $s_arrows_enabled = $_SESSION["s_arrows_enabled"];
- $s_mode = $_SESSION["s_mode"];
- $s_cycle_enabled = $_SESSION["s_cycle_enabled"];
- $s_x_margin = $_SESSION["s_x_margin"];
- $s_y_margin = $_SESSION["s_y_margin"];
- $s_automargin_enabled = $_SESSION["s_automargin_enabled"];
- $s_font = $_SESSION["s_font"];
- $s_font_size = $_SESSION["s_font_size"];
- $s_font_color = $_SESSION["s_font_color"];
-
- $s_x_labeling = $_SESSION["s_x_labeling"];
- $s_x_skip = $_SESSION["s_x_skip"];
- $s_x_label_rotation = $_SESSION["s_x_label_rotation"];
-
- $s_grid_color = $_SESSION["s_grid_color"];
- $s_grid_alpha = $_SESSION["s_grid_alpha"];
- $s_grid_x_enabled = $_SESSION["s_grid_x_enabled"];
- $s_grid_y_enabled = $_SESSION["s_grid_y_enabled"];
-
- $s_ticks_color = $_SESSION["s_ticks_color"];
- $s_ticks_alpha = $_SESSION["s_ticks_alpha"];
- $s_subticks_color = $_SESSION["s_subticks_color"];
- $s_subticks_alpha = $_SESSION["s_subticks_alpha"];
- $s_subticks_enabled = $_SESSION["s_subticks_enabled"];
- /* ------------------------------------------------------------------------ */
-
- /* -- Retrieve Chart configuration items ---------------------------------- */
- $c_family = $_SESSION["c_family"];
- $c_display_values = $_SESSION["c_display_values"];
- $c_break_color = $_SESSION["c_break_color"];
- $c_break = $_SESSION["c_break"];
-
- $c_plot_size = $_SESSION["c_plot_size"];
- $c_border_size = $_SESSION["c_border_size"];
- $c_border_enabled = $_SESSION["c_border_enabled"];
-
- $c_bar_classic = $_SESSION["c_bar_classic"];
- $c_bar_rounded = $_SESSION["c_bar_rounded"];
- $c_bar_gradient = $_SESSION["c_bar_gradient"];
- $c_around_zero1 = $_SESSION["c_around_zero1"];
-
- $c_transparency = $_SESSION["c_transparency"];
- $c_forced_transparency = $_SESSION["c_forced_transparency"];
- $c_around_zero2 = $_SESSION["c_around_zero2"];
- /* ------------------------------------------------------------------------ */
-
- /* -- Retrieve Legend configuration items ---------------------------------- */
- $l_enabled = $_SESSION["l_enabled"];
-
- $l_font = $_SESSION["l_font"];
- $l_font_size = $_SESSION["l_font_size"];
- $l_font_color = $_SESSION["l_font_color"];
-
- $l_margin = $_SESSION["l_margin"];
- $l_alpha = $_SESSION["l_alpha"];
- $l_format = $_SESSION["l_format"];
-
- $l_orientation = $_SESSION["l_orientation"];
- $l_box_size = $_SESSION["l_box_size"];
-
- $l_position = $_SESSION["l_position"];
- $l_x = $_SESSION["l_x"];
- $l_y = $_SESSION["l_y"];
-
- $l_family = $_SESSION["l_family"];
- /* ------------------------------------------------------------------------ */
-
- /* -- Retrieve Threshold configuration items ------------------------------ */
- $t_enabled = $_SESSION["t_enabled"];
-
- $t_value = $_SESSION["t_value"];
- $t_axis = $_SESSION["t_axis"];
-
- $t_color = $_SESSION["t_color"];
- $t_alpha = $_SESSION["t_alpha"];
- $t_ticks = $_SESSION["t_ticks"];
-
- $t_caption = $_SESSION["t_caption"];
- $t_box = $_SESSION["t_box"];
- $t_caption_enabled = $_SESSION["t_caption_enabled"];
- /* ------------------------------------------------------------------------ */
-
- /* -- Retrieve slope chart configuration items ---------------------------- */
- $sl_enabled = $_SESSION["sl_enabled"];
- $sl_shaded = $_SESSION["sl_shaded"];
- $sl_caption_enabled = $_SESSION["sl_caption_enabled"];
- $sl_caption_line = $_SESSION["sl_caption_line"];
- /* ------------------------------------------------------------------------ */
-
- /* -- Retrieve color configuration items ---------------------------------- */
- $p_template = $_SESSION["p_template"];
- /* ------------------------------------------------------------------------ */
-
-
- /* pChart library inclusions */
- include("../../../class/pData.class.php");
- include("../../../class/pDraw.class.php");
- include("../../../class/pImage.class.php");
-
- $myData = new pData();
- if ( $Mode == "Source" )
- {
- echo "&lt;?php\r\n";
- echo 'include("class/pData.class.php");'."\r\n";
- echo 'include("class/pDraw.class.php");'."\r\n";
- echo 'include("class/pImage.class.php");'."\r\n";
- echo "\r\n";
- echo '$myData = new pData();'."\r\n";
- }
-
- if ( $p_template != "default" )
- $myData->loadPalette("../../../palettes/".$p_template.".color",TRUE);
-
- $Axis = "";
- if ( $d_serie1_enabled == "true" )
- {
- $data0 = stripTail($data0);
- $Values = preg_split("/!/",right($data0,strlen($data0)-1));
- foreach($Values as $key => $Value)
- { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Serie1"); }
-
- $myData->setSerieDescription("Serie1",$d_serie1_name);
- $myData->setSerieOnAxis("Serie1",$d_serie1_axis);
- $Axis[$d_serie1_axis] = TRUE;
-
- if ( $Mode == "Source" )
- {
- $Data = "";
- foreach($Values as $key => $Value)
- { if ( $Value == "" || $Value == VOID ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
- $Data = right($Data,strlen($Data)-1);
-
- echo '$myData->addPoints(array('.$Data.'),"Serie1");'."\r\n";
- echo '$myData->setSerieDescription("Serie1","'.$d_serie1_name.'");'."\r\n";
- echo '$myData->setSerieOnAxis("Serie1",'.$d_serie1_axis.');'."\r\n\r\n";
-
- $Axis[$d_serie1_axis] = TRUE;
- }
- }
-
- if ( $d_serie2_enabled == "true" )
- {
- $data1 = stripTail($data1);
- $Values = preg_split("/!/",right($data1,strlen($data1)-1));
- foreach($Values as $key => $Value)
- { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Serie2"); }
-
- $myData->setSerieDescription("Serie2",$d_serie2_name);
- $myData->setSerieOnAxis("Serie2",$d_serie2_axis);
- $Axis[$d_serie2_axis] = TRUE;
-
- if ( $Mode == "Source" )
- {
- $Data = "";
- foreach($Values as $key => $Value)
- { if ( $Value == "" ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
- $Data = right($Data,strlen($Data)-1);
-
- echo '$myData->addPoints(array('.$Data.'),"Serie2");'."\r\n";
- echo '$myData->setSerieDescription("Serie2","'.$d_serie2_name.'");'."\r\n";
- echo '$myData->setSerieOnAxis("Serie2",'.$d_serie2_axis.');'."\r\n\r\n";
-
- $Axis[$d_serie2_axis] = TRUE;
- }
- }
-
- if ( $d_serie3_enabled == "true" )
- {
- $data2 = stripTail($data2);
- $Values = preg_split("/!/",right($data2,strlen($data2)-1));
- foreach($Values as $key => $Value)
- { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Serie3"); }
-
- $myData->setSerieDescription("Serie3",$d_serie3_name);
- $myData->setSerieOnAxis("Serie3",$d_serie3_axis);
- $Axis[$d_serie3_axis] = TRUE;
-
- if ( $Mode == "Source" )
- {
- $Data = "";
- foreach($Values as $key => $Value)
- { if ( $Value == "" ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
- $Data = right($Data,strlen($Data)-1);
-
- echo '$myData->addPoints(array('.$Data.'),"Serie3");'."\r\n";
- echo '$myData->setSerieDescription("Serie3","'.$d_serie3_name.'");'."\r\n";
- echo '$myData->setSerieOnAxis("Serie3",'.$d_serie3_axis.');'."\r\n\r\n";
-
- $Axis[$d_serie3_axis] = TRUE;
- }
- }
-
- if ( $d_absissa_enabled == "true" )
- {
- $absissa = stripTail($absissa);
- $Values = preg_split("/!/",right($absissa,strlen($absissa)-1));
- foreach($Values as $key => $Value)
- { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Absissa"); }
-
- $myData->setAbscissa("Absissa");
-
- if ( $Mode == "Source" )
- {
- $Data = "";
- foreach($Values as $key => $Value)
- { if ( $Value == "" ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
- $Data = right($Data,strlen($Data)-1);
-
- echo '$myData->addPoints(array('.$Data.'),"Absissa");'."\r\n";
- echo '$myData->setAbscissa("Absissa");'."\r\n\r\n";
- }
- }
-
- if ( isset($Axis[0]) )
- {
- if ( $d_axis0_position == "left" ) { $myData->setAxisPosition(0,AXIS_POSITION_LEFT); } else { $myData->setAxisPosition(0,AXIS_POSITION_RIGHT); }
- $myData->setAxisName(0,$d_axis0_name);
- $myData->setAxisUnit(0,$d_axis0_unit);
-
- if ( $d_axis0_format == "AXIS_FORMAT_METRIC" ) { $myData->setAxisDisplay(0,680004); }
- if ( $d_axis0_format == "AXIS_FORMAT_CURRENCY" ) { $myData->setAxisDisplay(0,680005,"$"); }
-
- if ( $Mode == "Source" )
- {
- if ( $d_axis0_position == "left" ) { echo '$myData->setAxisPosition(0,AXIS_POSITION_LEFT);'."\r\n"; } else { echo '$myData->setAxisPosition(0,AXIS_POSITION_RIGHT);'."\r\n"; }
- echo '$myData->setAxisName(0,"'.$d_axis0_name.'");'."\r\n";
- echo '$myData->setAxisUnit(0,"'.$d_axis0_unit.'");'."\r\n\r\n";
- }
- }
-
- if ( isset($Axis[1]) )
- {
- if ( $d_axis1_position == "left" ) { $myData->setAxisPosition(1,AXIS_POSITION_LEFT); } else { $myData->setAxisPosition(1,AXIS_POSITION_RIGHT); }
- $myData->setAxisName(1,$d_axis1_name);
- $myData->setAxisUnit(1,$d_axis1_unit);
-
- if ( $Mode == "Source" )
- {
- if ( $d_axis1_position == "left" ) { echo '$myData->setAxisPosition(1,AXIS_POSITION_LEFT);'."\r\n"; } else { echo '$myData->setAxisPosition(1,AXIS_POSITION_RIGHT);'."\r\n"; }
- echo '$myData->setAxisName(1,"'.$d_axis1_name.'");'."\r\n";
- echo '$myData->setAxisUnit(1,"'.$d_axis1_unit.'");'."\r\n\r\n";
- }
- }
-
- if ( isset($Axis[2]) )
- {
- if ( $d_axis2_position == "left" ) { $myData->setAxisPosition(2,AXIS_POSITION_LEFT); } else { $myData->setAxisPosition(2,AXIS_POSITION_RIGHT); }
- $myData->setAxisName(2,$d_axis2_name);
- $myData->setAxisUnit(2,$d_axis2_unit);
-
- if ( $Mode == "Source" )
- {
- if ( $d_axis2_position == "left" ) { echo '$myData->setAxisPosition(2,AXIS_POSITION_LEFT);'."\r\n"; } else { echo '$myData->setAxisPosition(2,AXIS_POSITION_RIGHT);'."\r\n"; }
- echo '$myData->setAxisName(2,"'.$d_axis2_name.'");'."\r\n";
- echo '$myData->setAxisUnit(2,"'.$d_axis2_unit.'");'."\r\n\r\n";
- }
- }
-
- if ( $d_normalize_enabled == "true" )
- {
- if ( $Mode == "Render" )
- $myData->normalize(100);
- else
- echo '$myData->normalize(100);'."\r\n";
- }
-
- if ( $Mode == "Render" )
- {
- if ( $g_transparent == "true" )
- $myPicture = new pImage($g_width,$g_height,$myData,TRUE);
- else
- $myPicture = new pImage($g_width,$g_height,$myData);
- }
- else
- {
- $myPicture = new pImage($g_width,$g_height,$myData);
- if ( $g_transparent == "true" )
- echo '$myPicture = new pImage('.$g_width.','.$g_height.',$myData,TRUE);'."\r\n";
- else
- echo '$myPicture = new pImage('.$g_width.','.$g_height.',$myData);'."\r\n";
- }
-
- if ( $g_aa == "false" )
- {
- if ( $Mode == "Render" )
- $myPicture->Antialias = FALSE;
- else
- echo '$myPicture->Antialias = FALSE;'."\r\n";
- }
-
- if ( $g_solid_enabled == "true" )
- {
- list($R,$G,$B) = extractColors($g_solid_color);
- $Settings = array("R"=>$R,"G"=>$G,"B"=>$B);
-
- if ( $g_solid_dashed == "true" ) { $Settings["Dash"] = TRUE; $Settings["DashR"]=$R+20; $Settings["DashG"]=$G+20; $Settings["DashB"]=$B+20; }
-
- if ( $Mode == "Render" )
- $myPicture->drawFilledRectangle(0,0,$g_width,$g_height,$Settings);
- else
- {
- echo dumpArray("Settings",$Settings);
- echo '$myPicture->drawFilledRectangle(0,0,'.$g_width.','.$g_height.',$Settings);'."\r\n\r\n";
- }
- }
-
- if ( $g_gradient_enabled == "true" )
- {
- list($StartR,$StartG,$StartB) = extractColors($g_gradient_start);
- list($EndR,$EndG,$EndB) = extractColors($g_gradient_end);
-
- $Settings = array("StartR"=>$StartR,"StartG"=>$StartG,"StartB"=>$StartB,"EndR"=>$EndR,"EndG"=>$EndG,"EndB"=>$EndB,"Alpha"=>$g_gradient_alpha);
-
- if ( $Mode == "Render" )
- {
- if ( $g_gradient_direction == "vertical" )
- $myPicture->drawGradientArea(0,0,$g_width,$g_height,DIRECTION_VERTICAL,$Settings);
- else
- $myPicture->drawGradientArea(0,0,$g_width,$g_height,DIRECTION_HORIZONTAL,$Settings);
- }
- else
- {
- echo dumpArray("Settings",$Settings);
-
- if ( $g_gradient_direction == "vertical" )
- echo '$myPicture->drawGradientArea(0,0,'.$g_width.','.$g_height.',DIRECTION_VERTICAL,$Settings);'."\r\n\r\n";
- else
- echo '$myPicture->drawGradientArea(0,0,'.$g_width.','.$g_height.',DIRECTION_HORIZONTAL,$Settings);'."\r\n\r\n";
- }
- }
-
- if ( $Mode == "Render" )
- {
- if ( $g_border == "true" ) { $myPicture->drawRectangle(0,0,$g_width-1,$g_height-1,array("R"=>0,"G"=>0,"B"=>0)); }
- if ( $g_shadow == "true" ) { $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>20)); }
- }
- else
- {
- if ( $g_border == "true" ) { echo '$myPicture->drawRectangle(0,0,'.($g_width-1).','.($g_height-1).',array("R"=>0,"G"=>0,"B"=>0));'."\r\n\r\n"; }
- if ( $g_shadow == "true" ) { echo '$myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>20));'."\r\n\r\n"; }
- }
-
- if ( $g_title_enabled == "true" )
- {
- if ( $Mode == "Render" )
- $myPicture->setFontProperties(array("FontName"=>"../../../fonts/".$g_title_font,"FontSize"=>$g_title_font_size));
- else
- echo '$myPicture->setFontProperties(array("FontName"=>"fonts/'.$g_title_font.'","FontSize"=>'.$g_title_font_size.'));'."\r\n";
-
- list($R,$G,$B) = extractColors($g_title_color);
-
- $TextSettings = array("Align"=>getTextAlignCode($g_title_align),"R"=>$R,"G"=>$G,"B"=>$B);
- if ( $g_title_box == "true" ) { $TextSettings["DrawBox"] = TRUE; $TextSettings["BoxAlpha"] = 30; }
-
- if ( $Mode == "Render" )
- $myPicture->drawText($g_title_x,$g_title_y,$g_title,$TextSettings);
- else
- {
- echo dumpArray("TextSettings",$TextSettings);
- echo '$myPicture->drawText('.$g_title_x.','.$g_title_y.',"'.$g_title.'",$TextSettings);'."\r\n\r\n";
- }
- }
-
- /* Scale section */
- if ( $Mode == "Render" )
- { if ( $g_shadow == "true" ) { $myPicture->setShadow(FALSE); } }
- else
- { if ( $g_shadow == "true" ) { echo '$myPicture->setShadow(FALSE);'."\r\n"; } }
-
- if ( $Mode == "Render" )
- $myPicture->setGraphArea($s_x,$s_y,$s_x+$s_width,$s_y+$s_height);
- else
- echo '$myPicture->setGraphArea('.$s_x.','.$s_y.','.($s_x+$s_width).','.($s_y+$s_height).');'."\r\n";
-
- list($R,$G,$B) = extractColors($s_font_color);
- if ( $Mode == "Render" )
- $myPicture->setFontProperties(array("R"=>$R,"G"=>$G,"B"=>$B,"FontName"=>"../../../fonts/".$s_font,"FontSize"=>$s_font_size));
- else
- echo '$myPicture->setFontProperties(array("R"=>'.$R.',"G"=>'.$G.',"B"=>'.$B.',"FontName"=>"fonts/'.$s_font.'","FontSize"=>'.$s_font_size.'));'."\r\n\r\n";
-
- /* Scale specific parameters -------------------------------------------------------------------------------- */
- list($GridR,$GridG,$GridB) = extractColors($s_grid_color);
- list($TickR,$TickG,$TickB) = extractColors($s_ticks_color);
- list($SubTickR,$SubTickG,$SubTickB) = extractColors($s_subticks_color);
-
- if ( $s_direction == "SCALE_POS_LEFTRIGHT" ) { $Pos = 690101; } else { $Pos = 690102; }
- if ( $s_x_labeling == "LABELING_ALL") { $Labeling = 691011; } else { $Labeling = 691012; }
- if ( $s_mode == "SCALE_MODE_FLOATING" ) { $iMode = 690201; }
- if ( $s_mode == "SCALE_MODE_START0" ) { $iMode = 690202; }
- if ( $s_mode == "SCALE_MODE_ADDALL" ) { $iMode = 690203; }
- if ( $s_mode == "SCALE_MODE_ADDALL_START0" ) { $iMode = 690204; }
-
- $Settings = array("Pos"=>$Pos,"Mode"=>$iMode,"LabelingMethod"=>$Labeling,"GridR"=>$GridR,"GridG"=>$GridG,"GridB"=>$GridB,"GridAlpha"=>$s_grid_alpha,"TickR"=>$TickR,"TickG"=>$TickG,"TickB"=>$TickB,"TickAlpha"=>$s_ticks_alpha,"LabelRotation"=>$s_x_label_rotation);
-
- if ( $s_x_skip != 0 ) { $Settings["LabelSkip"] = $s_x_skip; }
- if ( $s_cycle_enabled == "true" ) { $Settings["CycleBackground"] = TRUE; }
- if ( $s_arrows_enabled == "true" ) { $Settings["DrawArrows"] = TRUE; }
- if ( $s_grid_x_enabled == "true" ) { $Settings["DrawXLines"] = TRUE; } else { $Settings["DrawXLines"] = 0; }
- if ( $s_subticks_enabled == "true" )
- { $Settings["DrawSubTicks"] = TRUE; $Settings["SubTickR"] = $SubTickR; $Settings["SubTickG"] = $SubTickG; $Settings["SubTickB"] = $SubTickB; $Settings["SubTickAlpha"] = $s_subticks_alpha;}
- if ( $s_automargin_enabled == "false" )
- { $Settings["XMargin"] = $s_x_margin; $Settings["YMargin"] = $s_y_margin; }
-
- if ( $Mode == "Render" )
- {
- if ( $s_grid_y_enabled == "true" ) { $Settings["DrawYLines"] = ALL; } else { $Settings["DrawYLines"] = NONE; }
- $myPicture->drawScale($Settings);
- }
- else
- {
- if ( $s_grid_y_enabled == "true" ) { $Settings["DrawYLines"] = "ALL"; } else { $Settings["DrawYLines"] = "NONE"; }
- echo dumpArray("Settings",$Settings);
- echo '$myPicture->drawScale($Settings);'."\r\n\r\n";
- }
- /* ---------------------------------------------------------------------------------------------------------- */
-
- if ( $Mode == "Render" )
- { if ( $g_shadow == "true" ) { $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>10)); } }
- else
- { if ( $g_shadow == "true" ) { echo '$myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>10));'."\r\n\r\n"; } }
-
- /* Chart specific parameters -------------------------------------------------------------------------------- */
- if ( $c_display_values == "true" ) { $Config = array("DisplayValues"=>TRUE); } else { $Config = ""; }
-
- if ( $c_family == "plot" )
- {
- $Config["PlotSize"] = $c_plot_size;
- if ( $c_border_enabled == "true" ) { $Config["PlotBorder"] = TRUE; $Config["BorderSize"] = $c_border_size; }
-
- if ( $Mode == "Render" )
- $myPicture->drawPlotChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawPlotChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "line" )
- {
- if ( $c_break == "true" )
- {
- list($BreakR,$BreakG,$BreakB) = extractColors($c_break_color);
-
- $Config["BreakVoid"] = 0;
- $Config["BreakR"] = $BreakR;
- $Config["BreakG"] = $BreakG;
- $Config["BreakB"] = $BreakB;
- }
-
- if ( $Mode == "Render" )
- $myPicture->drawLineChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawLineChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "step" )
- {
- if ( $c_break == "true" )
- {
- list($BreakR,$BreakG,$BreakB) = extractColors($c_break_color);
-
- $Config["BreakVoid"] = 0;
- $Config["BreakR"] = $BreakR;
- $Config["BreakG"] = $BreakG;
- $Config["BreakB"] = $BreakB;
- }
-
- if ( $Mode == "Render" )
- $myPicture->drawStepChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawStepChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "spline" )
- {
- if ( $c_break == "true" )
- {
- list($BreakR,$BreakG,$BreakB) = extractColors($c_break_color);
-
- $Config["BreakVoid"] = 0;
- $Config["BreakR"] = $BreakR;
- $Config["BreakG"] = $BreakG;
- $Config["BreakB"] = $BreakB;
- }
-
- if ( $Mode == "Render" )
- $myPicture->drawSplineChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawSplineChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "bar" )
- {
- if ( $c_bar_rounded == "true" ) { $Config["Rounded"] = TRUE; }
- if ( $c_bar_gradient == "true" ) { $Config["Gradient"] = TRUE; }
- if ( $c_around_zero1 == "true" ) { $Config["AroundZero"] = TRUE; }
-
- if ( $Mode == "Render" )
- $myPicture->drawBarChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawBarChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "area" )
- {
- if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
- if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; }
-
- if ( $Mode == "Render" )
- $myPicture->drawAreaChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawAreaChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "fstep" )
- {
- if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
- if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; } else { $Config["AroundZero"] = FALSE; }
-
- if ( $Mode == "Render" )
- $myPicture->drawFilledStepChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawFilledStepChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "fspline" )
- {
- if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
- if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; }
-
- if ( $Mode == "Render" )
- $myPicture->drawFilledSplineChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawFilledSplineChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "sbar" )
- {
- if ( $c_bar_rounded == "true" ) { $Config["Rounded"] = TRUE; }
- if ( $c_bar_gradient == "true" ) { $Config["Gradient"] = TRUE; }
- if ( $c_around_zero1 == "true" ) { $Config["AroundZero"] = TRUE; }
-
- if ( $Mode == "Render" )
- $myPicture->drawStackedBarChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawStackedBarChart($Config);'."\r\n";
- }
- }
-
- if ( $c_family == "sarea" )
- {
- if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
- if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; }
-
- if ( $Mode == "Render" )
- $myPicture->drawStackedAreaChart($Config);
- else
- {
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawStackedAreaChart($Config);'."\r\n";
- }
- }
-
- if ( $t_enabled == "true" )
- {
- list($R,$G,$B) = extractColors($t_color);
-
- $Config = "";
- $Config["R"] = $R; $Config["G"] = $G; $Config["B"] = $B;
- $Config["Alpha"] = $t_alpha;
-
- if ( isset($myData->Data["Axis"][$t_axis]) ) { $Config["AxisID"] = $t_axis; }
-
- if ( $t_ticks == "true" ) { $Config["Ticks"] = 4; } else { $Config["Ticks"] = 0; }
-
- if ( $t_caption_enabled == "true" )
- {
- $Config["WriteCaption"] = TRUE;
- $Config["Caption"] = $t_caption;
- if ( $t_box == "true" ) { $Config["DrawBox"] = TRUE; }
- }
-
- if ( $Mode == "Render" )
- $myPicture->drawThreshold($t_value,$Config);
- else
- {
- $Config["Caption"] = chr(34).$t_caption.chr(34);
-
- echo "\r\n";
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawThreshold('.$t_value.',$Config);'."\r\n";
- }
- }
-
- if ( $l_enabled == "true" )
- {
- list($R,$G,$B) = extractColors($l_font_color);
-
- $Config = "";
- $Config["FontR"] = $R; $Config["FontG"] = $G; $Config["FontB"] = $B;
- $Config["FontName"] = "../../../fonts/".$l_font;
- $Config["FontSize"] = $l_font_size;
- $Config["Margin"] = $l_margin;
- $Config["Alpha"] = $l_alpha;
- $Config["BoxSize"] = $l_box_size;
-
- if ( $l_format == "LEGEND_NOBORDER" ) { $Config["Style"] = 690800; }
- if ( $l_format == "LEGEND_BOX" ) { $Config["Style"] = 690801; }
- if ( $l_format == "LEGEND_ROUND" ) { $Config["Style"] = 690802; }
-
- if ( $l_orientation == "LEGEND_VERTICAL" ) { $Config["Mode"] = 690901; }
- if ( $l_orientation == "LEGEND_HORIZONTAL" ) { $Config["Mode"] = 690902; }
-
- if ( $l_family == "LEGEND_FAMILY_CIRCLE" ) { $Config["Family"] = 691052; }
- if ( $l_family == "LEGEND_FAMILY_LINE" ) { $Config["Family"] = 691053; }
-
- $Size = $myPicture->getLegendSize($Config);
- if ( $l_position == "CORNER_TOP_RIGHT" )
- { $l_y = $l_margin + 10; $l_x = $g_width - $Size["Width"] - 10 + $l_margin; }
- if ( $l_position == "CORNER_BOTTOM_RIGHT" )
- { $l_y = $g_height - $Size["Height"] - 10 + $l_margin; $l_x = $g_width - $Size["Width"] - 10 + $l_margin; }
-
- if ( $Mode == "Render" )
- $myPicture->drawLegend($l_x,$l_y,$Config);
- else
- {
- $Config["FontName"] = chr(34)."fonts/".$l_font.chr(34);
-
- echo "\r\n";
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawLegend('.$l_x.','.$l_y.',$Config);'."\r\n";
- }
- }
-
- if ( $sl_enabled == "true" )
- {
- $Config = "";
- $Config["CaptionMargin"] = 10;
- $Config["CaptionWidth"] = 10;
-
- if ( $sl_shaded == "true" ) { $Config["ShadedSlopeBox"] = TRUE; }
- if ( $sl_caption_enabled != "true" ) { $Config["Caption"] = FALSE; }
- if ( $sl_caption_line == "true" ) { $Config["CaptionLine"] =TRUE; }
-
- if ( $Mode == "Render" )
- $myPicture->drawDerivative($Config);
- else
- {
- echo "\r\n";
- echo dumpArray("Config",$Config);
- echo '$myPicture->drawDerivative($Config);'."\r\n";
- }
- }
-
- if ( $Mode == "Render" )
- $myPicture->stroke();
- else
- echo "\r\n".'$myPicture->stroke();'."\r\n?>";
-
- function extractColors($Hexa)
- {
- if ( strlen($Hexa) != 6 ) { return(array(0,0,0)); }
-
- $R = hexdec(left($Hexa,2));
- $G = hexdec(mid($Hexa,3,2));
- $B = hexdec(right($Hexa,2));
-
- return(array($R,$G,$B));
- }
-
- function getTextAlignCode($Mode)
- {
- if ( $Mode == "TEXT_ALIGN_TOPLEFT" ) { return(690401); }
- if ( $Mode == "TEXT_ALIGN_TOPMIDDLE" ) { return(690402); }
- if ( $Mode == "TEXT_ALIGN_TOPRIGHT" ) { return(690403); }
- if ( $Mode == "TEXT_ALIGN_MIDDLELEFT" ) { return(690404); }
- if ( $Mode == "TEXT_ALIGN_MIDDLEMIDDLE" ) { return(690405); }
- if ( $Mode == "TEXT_ALIGN_MIDDLERIGHT" ) { return(690406); }
- if ( $Mode == "TEXT_ALIGN_BOTTOMLEFT" ) { return(690407); }
- if ( $Mode == "TEXT_ALIGN_BOTTOMMIDDLE" ) { return(690408); }
- if ( $Mode == "TEXT_ALIGN_BOTTOMRIGHT" ) { return(690409); }
- }
-
- function dumpArray($Name,$Values)
- {
- if ( $Values == "" ) { return('$'.$Name.' = "";'."\r\n"); }
-
- $Result = '$'.$Name." = array(";
- foreach ($Values as $Key => $Value)
- { $Result = $Result.chr(34).$Key.chr(34)."=>".translate($Value).", "; }
-
- $Result = left($Result,strlen($Result)-2).");\r\n";
-
- return($Result);
- }
-
- function translate($Value)
- {
- global $Constants;
-
- if ( isset($Constants[$Value]))
- return($Constants[$Value]);
- else
- return($Value);
- }
-
-
- function stripTail($Values)
- {
- $Values = preg_split("/!/",right($Values,strlen($Values)-1));
-
- $Temp = ""; $Result = "";
- foreach($Values as $Key => $Value)
- {
- if ( $Value == "" )
- { $Temp[] = VOID; }
- else
- {
- if ( $Temp != "" && $Result != "" )
- { $Result = array_merge($Result,$Temp); }
- elseif( $Temp != "" && $Result == "" )
- { $Result = $Temp; }
-
- $Result[] = $Value;
- $Temp = "";
- }
- }
-
- $Serialized = "!"; foreach($Result as $Key => $Value) { $Serialized = $Serialized.$Value."!"; }
- $Serialized = left($Serialized,strlen($Serialized)-1);
-
- return($Serialized);
- }
-
- function readConstantFile()
- {
- $FileName = "../includes/constants.txt";
-
- $handle = @fopen($FileName, "r");
- if ($handle)
- {
- $Result = "";
- while (($buffer = fgets($handle, 4096)) !== false)
- {
- $Values = preg_split("/,/",$buffer);
- $Result[$Values[0]] = $Values[1];
- }
- fclose($handle);
- return($Result);
- }
- else
- { return(array("VOID"=>"0.12345")); }
- }
-
- function toString($Value)
- {
- if ( is_numeric($Value) || $Value == "VOID")
- return($Value);
- else
- return(chr(34).$Value.chr(34));
- }
-
- function left($value,$NbChar)
- { return substr($value,0,$NbChar); }
-
- function right($value,$NbChar)
- { return substr($value,strlen($value)-$NbChar,$NbChar); }
-
- function mid($value,$Depart,$NbChar)
- { return substr($value,$Depart-1,$NbChar); }
-?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php b/notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php
deleted file mode 100644
index 697f9dd..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
- /*
- session.php - Sandbox sesson manager
-
- Version : 1.1.0
- Made by : Jean-Damien POGOLOTTI
- Last Update : 18/01/11
-
- This file can be distributed under the license you can find at :
-
- http://www.pchart.net/license
-
- You can find the whole class documentation on the pChart web site.
- */
-
- session_start();
-
- foreach($_GET as $Key => $Value)
- { $_SESSION[$Key] = $Value; }
-
- print_r($_SESSION);
-
- usleep(200000);
-?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/style.css b/notFinishedCode/pChart2.1.2/examples/sandbox/style.css
deleted file mode 100644
index 6ffbe70..0000000
--- a/notFinishedCode/pChart2.1.2/examples/sandbox/style.css
+++ /dev/null
@@ -1,89 +0,0 @@
-body
- {
- margin: 4px;
- text-align: left;
- font-family: tahoma;
- background-color: #FFFFFF;
- background-image: url('graphix/background.console.png');
- }
-
-table { margin: 0px; padding: 0px;}
-
-td { margin: 0px; padding: 0px; }
-
-tr { margin: 0px; padding: 0px; }
-
-td.topMenu { font-family: tahoma; font-size: 11px; }
-
-div.roundedCorner { font-size: 10px; }
-
-div.topMenu { border: 1px solid #FEFEFE; background-color: #EAEAEA; cursor: hand; cursor: pointer; }
-
-input
- {
- font-family: tahoma;
- font-size: 10px;
- }
-
-input[type="text"]
- {
- width: 325px;
- border: 1px solid #D0D0D0;
- background-color: #FFFFFF;
- vertical-align: middle;
- font-weight: normal;
- color: #707070;
- outline: none;
- height: 15px;
- }
-
-select
- {
- border: 1px solid #D0D0D0;
- background-color: #FFFFFF;
- vertical-align: middle;
- font-weight: normal;
- color: #707070;
- outline: none;
- font-size: 10px;
- height: 19px;
- }
-
-input[type="submit"]
- {
- border: 1px solid #D0D0D0;
- background-color: #FFFFFF;
- vertical-align: middle;
- font-weight: normal;
- color: #707070;
- outline: none;
- }
-
-pre
- {
- font-family; tahoma;
- font-size: 11px;
- background-color: #FFFFFF;
- border: 1px solid #E0E0E0;
- padding: 5px;
- margin-top: 20px;
- text-align: left;
- overflow-x: auto;
- white-space: pre-wrap;
- white-space: -moz-pre-wrap !important;
- white-space: -pre-wrap;
- white-space: -o-pre-wrap;
- word-wrap: break-word;
- }
-
-a.link:link { text-decoration: none; }
-a.link:visited { text-decoration: none; }
-a.link:hover { text-decoration: underline; }
-
-a.smallLinkGrey:link { text-decoration: none; color: #6A6A6A; }
-a.smallLinkGrey:visited { text-decoration: none; color: #6A6A6A; }
-a.smallLinkGrey:hover { text-decoration: underline; color: #6A6A6A; }
-
-a.smallLinkBlack:link { text-decoration: none; color: #000000; }
-a.smallLinkBlack:visited { text-decoration: none; color: #000000; }
-a.smallLinkBlack:hover { text-decoration: underline; color: #000000; }