Initial import of files not touched since 2006
authorKristian Fiskerstrand <kf@sumptuouscapital.com>
Sun, 8 Nov 2015 17:14:57 +0000 (18:14 +0100)
committerKristian Fiskerstrand <kf@sumptuouscapital.com>
Sun, 8 Nov 2015 17:14:57 +0000 (18:14 +0100)
25 files changed:
Chart/DrawChart.cfg [new file with mode: 0755]
Chart/DrawChart.dof [new file with mode: 0755]
Chart/DrawChart.dpr [new file with mode: 0755]
Chart/DrawChart.res [new file with mode: 0755]
Chart/DrawChart.tlb [new file with mode: 0755]
Chart/DrawChart.~dpr [new file with mode: 0755]
Chart/DrawChart.~tlb [new file with mode: 0755]
Chart/DrawChart_TLB.dcu [new file with mode: 0755]
Chart/DrawChart_TLB.pas [new file with mode: 0755]
Chart/DrawChart_TLB.~pas [new file with mode: 0755]
Chart/KFWDrawChart.cfg [new file with mode: 0755]
Chart/KFWDrawChart.dof [new file with mode: 0755]
Chart/KFWDrawChart.dpr [new file with mode: 0755]
Chart/KFWDrawChart.res [new file with mode: 0755]
Chart/KFWDrawChart.tlb [new file with mode: 0755]
Chart/Project1.cfg [new file with mode: 0755]
Chart/Project1.dof [new file with mode: 0755]
Chart/Project1.dpr [new file with mode: 0755]
Chart/Project1.res [new file with mode: 0755]
Chart/Project1.~dpr [new file with mode: 0755]
Chart/Unit1.dcu [new file with mode: 0755]
Chart/Unit1.pas [new file with mode: 0755]
Chart/Unit1.~pas [new file with mode: 0755]
DrawChart.asp [new file with mode: 0755]
DrawChart.dll [new file with mode: 0755]

diff --git a/Chart/DrawChart.cfg b/Chart/DrawChart.cfg
new file mode 100755 (executable)
index 0000000..77c144b
--- /dev/null
@@ -0,0 +1,35 @@
+-$A8\r
+-$B-\r
+-$C+\r
+-$D+\r
+-$E-\r
+-$F-\r
+-$G+\r
+-$H+\r
+-$I+\r
+-$J-\r
+-$K-\r
+-$L+\r
+-$M-\r
+-$N+\r
+-$O+\r
+-$P+\r
+-$Q-\r
+-$R-\r
+-$S-\r
+-$T-\r
+-$U-\r
+-$V+\r
+-$W-\r
+-$X+\r
+-$YD\r
+-$Z1\r
+-cg\r
+-AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
+-H+\r
+-W+\r
+-M\r
+-$M16384,1048576\r
+-K$00400000\r
+-LE"c:\programfiler\borland\delphi6\Projects\Bpl"\r
+-LN"c:\programfiler\borland\delphi6\Projects\Bpl"\r
diff --git a/Chart/DrawChart.dof b/Chart/DrawChart.dof
new file mode 100755 (executable)
index 0000000..ef8c11e
--- /dev/null
@@ -0,0 +1,90 @@
+[FileVersion]\r
+Version=6.0\r
+[Compiler]\r
+A=8\r
+B=0\r
+C=1\r
+D=1\r
+E=0\r
+F=0\r
+G=1\r
+H=1\r
+I=1\r
+J=0\r
+K=0\r
+L=1\r
+M=0\r
+N=1\r
+O=1\r
+P=1\r
+Q=0\r
+R=0\r
+S=0\r
+T=0\r
+U=0\r
+V=1\r
+W=0\r
+X=1\r
+Y=1\r
+Z=1\r
+ShowHints=1\r
+ShowWarnings=1\r
+UnitAliases=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
+[Linker]\r
+MapFile=0\r
+OutputObjs=0\r
+ConsoleApp=1\r
+DebugInfo=0\r
+RemoteSymbols=0\r
+MinStackSize=16384\r
+MaxStackSize=1048576\r
+ImageBase=4194304\r
+ExeDescription=\r
+[Directories]\r
+OutputDir=\r
+UnitOutputDir=\r
+PackageDLLOutputDir=\r
+PackageDCPOutputDir=\r
+SearchPath=\r
+Packages=vcl;rtl;dbrtl;adortl;vcldb;vclx;bdertl;vcldbx;ibxpress;dsnap;cds;bdecds;qrpt;teeui;teedb;tee;dss;teeqr;visualclx;visualdbclx;dsnapcrba;dsnapcon;VclSmp;vclshlctrls;vclie;xmlrtl;inet;inetdbbde;inetdbxpress;inetdb;nmfast;webdsnap;websnap;dbexpress;dbxcds;indy;dclOffice2k\r
+Conditionals=\r
+DebugSourceDirs=\r
+UsePackages=0\r
+[Parameters]\r
+RunParams=\r
+HostApplication=\r
+Launcher=\r
+UseLauncher=0\r
+DebugCWD=\r
+[Language]\r
+ActiveLang=\r
+ProjectLang=\r
+RootDir=\r
+[Version Info]\r
+IncludeVerInfo=1\r
+AutoIncBuild=1\r
+MajorVer=0\r
+MinorVer=9\r
+Release=0\r
+Build=7\r
+Debug=1\r
+PreRelease=0\r
+Special=0\r
+Private=0\r
+DLL=1\r
+Locale=1033\r
+CodePage=1252\r
+[Version Info Keys]\r
+CompanyName=KF Webs\r
+FileDescription=\r
+FileVersion=0.9.0.7\r
+InternalName=\r
+LegalCopyright=\r
+LegalTrademarks=\r
+OriginalFilename=\r
+ProductName=DrawChart\r
+ProductVersion=1.0.0.0\r
+Comments=\r
+[HistoryLists\hlUnitAliases]\r
+Count=1\r
+Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
diff --git a/Chart/DrawChart.dpr b/Chart/DrawChart.dpr
new file mode 100755 (executable)
index 0000000..7110d0e
--- /dev/null
@@ -0,0 +1,19 @@
+library DrawChart;\r
+\r
+uses\r
+  ComServ,\r
+  DrawChart_TLB in 'DrawChart_TLB.pas',\r
+  Unit1 in 'Unit1.pas' {Draw: CoClass};\r
+\r
+exports\r
+  DllGetClassObject,\r
+  DllCanUnloadNow,\r
+  DllRegisterServer,\r
+  DllUnregisterServer;\r
+\r
+{$R *.TLB}\r
+\r
+{$R *.RES}\r
+\r
+begin\r
+end.\r
diff --git a/Chart/DrawChart.res b/Chart/DrawChart.res
new file mode 100755 (executable)
index 0000000..8e0750c
Binary files /dev/null and b/Chart/DrawChart.res differ
diff --git a/Chart/DrawChart.tlb b/Chart/DrawChart.tlb
new file mode 100755 (executable)
index 0000000..33094db
Binary files /dev/null and b/Chart/DrawChart.tlb differ
diff --git a/Chart/DrawChart.~dpr b/Chart/DrawChart.~dpr
new file mode 100755 (executable)
index 0000000..7110d0e
--- /dev/null
@@ -0,0 +1,19 @@
+library DrawChart;\r
+\r
+uses\r
+  ComServ,\r
+  DrawChart_TLB in 'DrawChart_TLB.pas',\r
+  Unit1 in 'Unit1.pas' {Draw: CoClass};\r
+\r
+exports\r
+  DllGetClassObject,\r
+  DllCanUnloadNow,\r
+  DllRegisterServer,\r
+  DllUnregisterServer;\r
+\r
+{$R *.TLB}\r
+\r
+{$R *.RES}\r
+\r
+begin\r
+end.\r
diff --git a/Chart/DrawChart.~tlb b/Chart/DrawChart.~tlb
new file mode 100755 (executable)
index 0000000..33094db
Binary files /dev/null and b/Chart/DrawChart.~tlb differ
diff --git a/Chart/DrawChart_TLB.dcu b/Chart/DrawChart_TLB.dcu
new file mode 100755 (executable)
index 0000000..25635df
Binary files /dev/null and b/Chart/DrawChart_TLB.dcu differ
diff --git a/Chart/DrawChart_TLB.pas b/Chart/DrawChart_TLB.pas
new file mode 100755 (executable)
index 0000000..6b46fb7
--- /dev/null
@@ -0,0 +1,160 @@
+unit DrawChart_TLB;\r
+\r
+// ************************************************************************ //\r
+// WARNING                                                                    \r
+// -------                                                                    \r
+// The types declared in this file were generated from data read from a       \r
+// Type Library. If this type library is explicitly or indirectly (via        \r
+// another type library referring to this type library) re-imported, or the   \r
+// 'Refresh' command of the Type Library Editor activated while editing the   \r
+// Type Library, the contents of this file will be regenerated and all        \r
+// manual modifications will be lost.                                         \r
+// ************************************************************************ //\r
+\r
+// PASTLWTR : $Revision:   1.130  $\r
+// File generated on 26.07.2002 16:31:42 from Type Library described below.\r
+\r
+// ************************************************************************  //\r
+// Type Lib: C:\Chart\DrawChart.tlb (1)\r
+// LIBID: {78F02555-6FF9-4A7D-B141-6681BC7C18E9}\r
+// LCID: 0\r
+// Helpfile: \r
+// DepndLst: \r
+//   (1) v2.0 stdole, (C:\WINDOWS\System32\stdole2.tlb)\r
+//   (2) v4.0 StdVCL, (C:\WINDOWS\System32\stdvcl40.dll)\r
+// ************************************************************************ //\r
+{$TYPEDADDRESS OFF} // Unit must be compiled without type-checked pointers. \r
+{$WARN SYMBOL_PLATFORM OFF}\r
+{$WRITEABLECONST ON}\r
+\r
+interface\r
+\r
+uses ActiveX, Classes, Graphics, StdVCL, Variants, Windows;\r
+  \r
+\r
+// *********************************************************************//\r
+// GUIDS declared in the TypeLibrary. Following prefixes are used:        \r
+//   Type Libraries     : LIBID_xxxx                                      \r
+//   CoClasses          : CLASS_xxxx                                      \r
+//   DISPInterfaces     : DIID_xxxx                                       \r
+//   Non-DISP interfaces: IID_xxxx                                        \r
+// *********************************************************************//\r
+const\r
+  // TypeLibrary Major and minor versions\r
+  DrawChartMajorVersion = 1;\r
+  DrawChartMinorVersion = 0;\r
+\r
+  LIBID_DrawChart: TGUID = '{78F02555-6FF9-4A7D-B141-6681BC7C18E9}';\r
+\r
+  IID_IDraw: TGUID = '{A02B5042-50BA-491E-94C6-65C6E4016D2D}';\r
+  CLASS_Draw: TGUID = '{B6AC8F19-FC50-4BCE-A5D9-DBDDA0C26494}';\r
+type\r
+\r
+// *********************************************************************//\r
+// Forward declaration of types defined in TypeLibrary                    \r
+// *********************************************************************//\r
+  IDraw = interface;\r
+  IDrawDisp = dispinterface;\r
+\r
+// *********************************************************************//\r
+// Declaration of CoClasses defined in Type Library                       \r
+// (NOTE: Here we map each CoClass to its Default Interface)              \r
+// *********************************************************************//\r
+  Draw = IDraw;\r
+\r
+\r
+// *********************************************************************//\r
+// Interface: IDraw\r
+// Flags:     (4416) Dual OleAutomation Dispatchable\r
+// GUID:      {A02B5042-50BA-491E-94C6-65C6E4016D2D}\r
+// *********************************************************************//\r
+  IDraw = interface(IDispatch)\r
+    ['{A02B5042-50BA-491E-94C6-65C6E4016D2D}']\r
+    function  Get_Height: Integer; safecall;\r
+    procedure Set_Height(Value: Integer); safecall;\r
+    function  Get_Width: Integer; safecall;\r
+    procedure Set_Width(Value: Integer); safecall;\r
+    function  Get_Data: WideString; safecall;\r
+    procedure Set_Data(const Value: WideString); safecall;\r
+    function  Get_Values: WideString; safecall;\r
+    procedure Set_Values(const Value: WideString); safecall;\r
+    function  Get_Title: WideString; safecall;\r
+    procedure Set_Title(const Value: WideString); safecall;\r
+    function  Get_Legend: WordBool; safecall;\r
+    procedure Set_Legend(Value: WordBool); safecall;\r
+    function  Get_Style: Integer; safecall;\r
+    procedure Set_Style(Value: Integer); safecall;\r
+    function  Get_View3d: WordBool; safecall;\r
+    procedure Set_View3d(Value: WordBool); safecall;\r
+    function  Get_Stairs: WordBool; safecall;\r
+    procedure Set_Stairs(Value: WordBool); safecall;\r
+    procedure Draw; safecall;\r
+    function  Get_Color: WideString; safecall;\r
+    procedure Set_Color(const Value: WideString); safecall;\r
+    function  Get_bgColor: WideString; safecall;\r
+    procedure Set_bgColor(const Value: WideString); safecall;\r
+    function  Get_wallColor: WideString; safecall;\r
+    procedure Set_wallColor(const Value: WideString); safecall;\r
+    property Height: Integer read Get_Height write Set_Height;\r
+    property Width: Integer read Get_Width write Set_Width;\r
+    property Data: WideString read Get_Data write Set_Data;\r
+    property Values: WideString read Get_Values write Set_Values;\r
+    property Title: WideString read Get_Title write Set_Title;\r
+    property Legend: WordBool read Get_Legend write Set_Legend;\r
+    property Style: Integer read Get_Style write Set_Style;\r
+    property View3d: WordBool read Get_View3d write Set_View3d;\r
+    property Stairs: WordBool read Get_Stairs write Set_Stairs;\r
+    property Color: WideString read Get_Color write Set_Color;\r
+    property bgColor: WideString read Get_bgColor write Set_bgColor;\r
+    property wallColor: WideString read Get_wallColor write Set_wallColor;\r
+  end;\r
+\r
+// *********************************************************************//\r
+// DispIntf:  IDrawDisp\r
+// Flags:     (4416) Dual OleAutomation Dispatchable\r
+// GUID:      {A02B5042-50BA-491E-94C6-65C6E4016D2D}\r
+// *********************************************************************//\r
+  IDrawDisp = dispinterface\r
+    ['{A02B5042-50BA-491E-94C6-65C6E4016D2D}']\r
+    property Height: Integer dispid 1;\r
+    property Width: Integer dispid 2;\r
+    property Data: WideString dispid 3;\r
+    property Values: WideString dispid 4;\r
+    property Title: WideString dispid 5;\r
+    property Legend: WordBool dispid 6;\r
+    property Style: Integer dispid 7;\r
+    property View3d: WordBool dispid 8;\r
+    property Stairs: WordBool dispid 9;\r
+    procedure Draw; dispid 10;\r
+    property Color: WideString dispid 11;\r
+    property bgColor: WideString dispid 12;\r
+    property wallColor: WideString dispid 13;\r
+  end;\r
+\r
+// *********************************************************************//\r
+// The Class CoDraw provides a Create and CreateRemote method to          \r
+// create instances of the default interface IDraw exposed by              \r
+// the CoClass Draw. The functions are intended to be used by             \r
+// clients wishing to automate the CoClass objects exposed by the         \r
+// server of this typelibrary.                                            \r
+// *********************************************************************//\r
+  CoDraw = class\r
+    class function Create: IDraw;\r
+    class function CreateRemote(const MachineName: string): IDraw;\r
+  end;\r
+\r
+implementation\r
+\r
+uses ComObj;\r
+\r
+class function CoDraw.Create: IDraw;\r
+begin\r
+  Result := CreateComObject(CLASS_Draw) as IDraw;\r
+end;\r
+\r
+class function CoDraw.CreateRemote(const MachineName: string): IDraw;\r
+begin\r
+  Result := CreateRemoteComObject(MachineName, CLASS_Draw) as IDraw;\r
+end;\r
+\r
+end.\r
diff --git a/Chart/DrawChart_TLB.~pas b/Chart/DrawChart_TLB.~pas
new file mode 100755 (executable)
index 0000000..6b46fb7
--- /dev/null
@@ -0,0 +1,160 @@
+unit DrawChart_TLB;\r
+\r
+// ************************************************************************ //\r
+// WARNING                                                                    \r
+// -------                                                                    \r
+// The types declared in this file were generated from data read from a       \r
+// Type Library. If this type library is explicitly or indirectly (via        \r
+// another type library referring to this type library) re-imported, or the   \r
+// 'Refresh' command of the Type Library Editor activated while editing the   \r
+// Type Library, the contents of this file will be regenerated and all        \r
+// manual modifications will be lost.                                         \r
+// ************************************************************************ //\r
+\r
+// PASTLWTR : $Revision:   1.130  $\r
+// File generated on 26.07.2002 16:31:42 from Type Library described below.\r
+\r
+// ************************************************************************  //\r
+// Type Lib: C:\Chart\DrawChart.tlb (1)\r
+// LIBID: {78F02555-6FF9-4A7D-B141-6681BC7C18E9}\r
+// LCID: 0\r
+// Helpfile: \r
+// DepndLst: \r
+//   (1) v2.0 stdole, (C:\WINDOWS\System32\stdole2.tlb)\r
+//   (2) v4.0 StdVCL, (C:\WINDOWS\System32\stdvcl40.dll)\r
+// ************************************************************************ //\r
+{$TYPEDADDRESS OFF} // Unit must be compiled without type-checked pointers. \r
+{$WARN SYMBOL_PLATFORM OFF}\r
+{$WRITEABLECONST ON}\r
+\r
+interface\r
+\r
+uses ActiveX, Classes, Graphics, StdVCL, Variants, Windows;\r
+  \r
+\r
+// *********************************************************************//\r
+// GUIDS declared in the TypeLibrary. Following prefixes are used:        \r
+//   Type Libraries     : LIBID_xxxx                                      \r
+//   CoClasses          : CLASS_xxxx                                      \r
+//   DISPInterfaces     : DIID_xxxx                                       \r
+//   Non-DISP interfaces: IID_xxxx                                        \r
+// *********************************************************************//\r
+const\r
+  // TypeLibrary Major and minor versions\r
+  DrawChartMajorVersion = 1;\r
+  DrawChartMinorVersion = 0;\r
+\r
+  LIBID_DrawChart: TGUID = '{78F02555-6FF9-4A7D-B141-6681BC7C18E9}';\r
+\r
+  IID_IDraw: TGUID = '{A02B5042-50BA-491E-94C6-65C6E4016D2D}';\r
+  CLASS_Draw: TGUID = '{B6AC8F19-FC50-4BCE-A5D9-DBDDA0C26494}';\r
+type\r
+\r
+// *********************************************************************//\r
+// Forward declaration of types defined in TypeLibrary                    \r
+// *********************************************************************//\r
+  IDraw = interface;\r
+  IDrawDisp = dispinterface;\r
+\r
+// *********************************************************************//\r
+// Declaration of CoClasses defined in Type Library                       \r
+// (NOTE: Here we map each CoClass to its Default Interface)              \r
+// *********************************************************************//\r
+  Draw = IDraw;\r
+\r
+\r
+// *********************************************************************//\r
+// Interface: IDraw\r
+// Flags:     (4416) Dual OleAutomation Dispatchable\r
+// GUID:      {A02B5042-50BA-491E-94C6-65C6E4016D2D}\r
+// *********************************************************************//\r
+  IDraw = interface(IDispatch)\r
+    ['{A02B5042-50BA-491E-94C6-65C6E4016D2D}']\r
+    function  Get_Height: Integer; safecall;\r
+    procedure Set_Height(Value: Integer); safecall;\r
+    function  Get_Width: Integer; safecall;\r
+    procedure Set_Width(Value: Integer); safecall;\r
+    function  Get_Data: WideString; safecall;\r
+    procedure Set_Data(const Value: WideString); safecall;\r
+    function  Get_Values: WideString; safecall;\r
+    procedure Set_Values(const Value: WideString); safecall;\r
+    function  Get_Title: WideString; safecall;\r
+    procedure Set_Title(const Value: WideString); safecall;\r
+    function  Get_Legend: WordBool; safecall;\r
+    procedure Set_Legend(Value: WordBool); safecall;\r
+    function  Get_Style: Integer; safecall;\r
+    procedure Set_Style(Value: Integer); safecall;\r
+    function  Get_View3d: WordBool; safecall;\r
+    procedure Set_View3d(Value: WordBool); safecall;\r
+    function  Get_Stairs: WordBool; safecall;\r
+    procedure Set_Stairs(Value: WordBool); safecall;\r
+    procedure Draw; safecall;\r
+    function  Get_Color: WideString; safecall;\r
+    procedure Set_Color(const Value: WideString); safecall;\r
+    function  Get_bgColor: WideString; safecall;\r
+    procedure Set_bgColor(const Value: WideString); safecall;\r
+    function  Get_wallColor: WideString; safecall;\r
+    procedure Set_wallColor(const Value: WideString); safecall;\r
+    property Height: Integer read Get_Height write Set_Height;\r
+    property Width: Integer read Get_Width write Set_Width;\r
+    property Data: WideString read Get_Data write Set_Data;\r
+    property Values: WideString read Get_Values write Set_Values;\r
+    property Title: WideString read Get_Title write Set_Title;\r
+    property Legend: WordBool read Get_Legend write Set_Legend;\r
+    property Style: Integer read Get_Style write Set_Style;\r
+    property View3d: WordBool read Get_View3d write Set_View3d;\r
+    property Stairs: WordBool read Get_Stairs write Set_Stairs;\r
+    property Color: WideString read Get_Color write Set_Color;\r
+    property bgColor: WideString read Get_bgColor write Set_bgColor;\r
+    property wallColor: WideString read Get_wallColor write Set_wallColor;\r
+  end;\r
+\r
+// *********************************************************************//\r
+// DispIntf:  IDrawDisp\r
+// Flags:     (4416) Dual OleAutomation Dispatchable\r
+// GUID:      {A02B5042-50BA-491E-94C6-65C6E4016D2D}\r
+// *********************************************************************//\r
+  IDrawDisp = dispinterface\r
+    ['{A02B5042-50BA-491E-94C6-65C6E4016D2D}']\r
+    property Height: Integer dispid 1;\r
+    property Width: Integer dispid 2;\r
+    property Data: WideString dispid 3;\r
+    property Values: WideString dispid 4;\r
+    property Title: WideString dispid 5;\r
+    property Legend: WordBool dispid 6;\r
+    property Style: Integer dispid 7;\r
+    property View3d: WordBool dispid 8;\r
+    property Stairs: WordBool dispid 9;\r
+    procedure Draw; dispid 10;\r
+    property Color: WideString dispid 11;\r
+    property bgColor: WideString dispid 12;\r
+    property wallColor: WideString dispid 13;\r
+  end;\r
+\r
+// *********************************************************************//\r
+// The Class CoDraw provides a Create and CreateRemote method to          \r
+// create instances of the default interface IDraw exposed by              \r
+// the CoClass Draw. The functions are intended to be used by             \r
+// clients wishing to automate the CoClass objects exposed by the         \r
+// server of this typelibrary.                                            \r
+// *********************************************************************//\r
+  CoDraw = class\r
+    class function Create: IDraw;\r
+    class function CreateRemote(const MachineName: string): IDraw;\r
+  end;\r
+\r
+implementation\r
+\r
+uses ComObj;\r
+\r
+class function CoDraw.Create: IDraw;\r
+begin\r
+  Result := CreateComObject(CLASS_Draw) as IDraw;\r
+end;\r
+\r
+class function CoDraw.CreateRemote(const MachineName: string): IDraw;\r
+begin\r
+  Result := CreateRemoteComObject(MachineName, CLASS_Draw) as IDraw;\r
+end;\r
+\r
+end.\r
diff --git a/Chart/KFWDrawChart.cfg b/Chart/KFWDrawChart.cfg
new file mode 100755 (executable)
index 0000000..dc18277
--- /dev/null
@@ -0,0 +1,35 @@
+-$A8\r
+-$B-\r
+-$C+\r
+-$D+\r
+-$E-\r
+-$F-\r
+-$G+\r
+-$H+\r
+-$I+\r
+-$J-\r
+-$K-\r
+-$L+\r
+-$M-\r
+-$N+\r
+-$O+\r
+-$P+\r
+-$Q-\r
+-$R-\r
+-$S-\r
+-$T-\r
+-$U-\r
+-$V+\r
+-$W-\r
+-$X+\r
+-$YD\r
+-$Z1\r
+-cg\r
+-AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
+-H+\r
+-W+\r
+-M\r
+-$M16384,1048576\r
+-K$00400000\r
+-LE"c:\program files\borland\delphi6\Projects\Bpl"\r
+-LN"c:\program files\borland\delphi6\Projects\Bpl"\r
diff --git a/Chart/KFWDrawChart.dof b/Chart/KFWDrawChart.dof
new file mode 100755 (executable)
index 0000000..6242c39
--- /dev/null
@@ -0,0 +1,90 @@
+[FileVersion]\r
+Version=6.0\r
+[Compiler]\r
+A=8\r
+B=0\r
+C=1\r
+D=1\r
+E=0\r
+F=0\r
+G=1\r
+H=1\r
+I=1\r
+J=0\r
+K=0\r
+L=1\r
+M=0\r
+N=1\r
+O=1\r
+P=1\r
+Q=0\r
+R=0\r
+S=0\r
+T=0\r
+U=0\r
+V=1\r
+W=0\r
+X=1\r
+Y=1\r
+Z=1\r
+ShowHints=1\r
+ShowWarnings=1\r
+UnitAliases=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
+[Linker]\r
+MapFile=0\r
+OutputObjs=0\r
+ConsoleApp=1\r
+DebugInfo=0\r
+RemoteSymbols=0\r
+MinStackSize=16384\r
+MaxStackSize=1048576\r
+ImageBase=4194304\r
+ExeDescription=\r
+[Directories]\r
+OutputDir=\r
+UnitOutputDir=\r
+PackageDLLOutputDir=\r
+PackageDCPOutputDir=\r
+SearchPath=\r
+Packages=vcl;rtl;dbrtl;adortl;vcldb;vclx;bdertl;vcldbx;ibxpress;dsnap;cds;bdecds;qrpt;teeui;teedb;tee;dss;teeqr;visualclx;visualdbclx;dsnapcrba;dsnapcon;VclSmp;vclshlctrls;vclie;xmlrtl;inet;inetdbbde;inetdbxpress;inetdb;nmfast;webdsnap;websnap;dbexpress;dbxcds;indy;dclOffice2k\r
+Conditionals=\r
+DebugSourceDirs=\r
+UsePackages=0\r
+[Parameters]\r
+RunParams=\r
+HostApplication=\r
+Launcher=\r
+UseLauncher=0\r
+DebugCWD=\r
+[Language]\r
+ActiveLang=\r
+ProjectLang=\r
+RootDir=\r
+[Version Info]\r
+IncludeVerInfo=1\r
+AutoIncBuild=1\r
+MajorVer=0\r
+MinorVer=1\r
+Release=0\r
+Build=2\r
+Debug=1\r
+PreRelease=0\r
+Special=0\r
+Private=0\r
+DLL=1\r
+Locale=1033\r
+CodePage=1252\r
+[Version Info Keys]\r
+CompanyName=KF Webs\r
+FileDescription=\r
+FileVersion=0.1.0.2\r
+InternalName=\r
+LegalCopyright=\r
+LegalTrademarks=\r
+OriginalFilename=\r
+ProductName=DrawChart\r
+ProductVersion=1.0.0.0\r
+Comments=\r
+[HistoryLists\hlUnitAliases]\r
+Count=1\r
+Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
diff --git a/Chart/KFWDrawChart.dpr b/Chart/KFWDrawChart.dpr
new file mode 100755 (executable)
index 0000000..cbb86c3
--- /dev/null
@@ -0,0 +1,19 @@
+library KFWDrawChart;\r
+\r
+uses\r
+  ComServ,\r
+  DrawChart_TLB in 'DrawChart_TLB.pas',\r
+  Unit1 in 'Unit1.pas' {Draw: CoClass};\r
+\r
+exports\r
+  DllGetClassObject,\r
+  DllCanUnloadNow,\r
+  DllRegisterServer,\r
+  DllUnregisterServer;\r
+\r
+{$R *.TLB}\r
+\r
+{$R *.RES}\r
+\r
+begin\r
+end.\r
diff --git a/Chart/KFWDrawChart.res b/Chart/KFWDrawChart.res
new file mode 100755 (executable)
index 0000000..db93e80
Binary files /dev/null and b/Chart/KFWDrawChart.res differ
diff --git a/Chart/KFWDrawChart.tlb b/Chart/KFWDrawChart.tlb
new file mode 100755 (executable)
index 0000000..cd6245e
Binary files /dev/null and b/Chart/KFWDrawChart.tlb differ
diff --git a/Chart/Project1.cfg b/Chart/Project1.cfg
new file mode 100755 (executable)
index 0000000..dc18277
--- /dev/null
@@ -0,0 +1,35 @@
+-$A8\r
+-$B-\r
+-$C+\r
+-$D+\r
+-$E-\r
+-$F-\r
+-$G+\r
+-$H+\r
+-$I+\r
+-$J-\r
+-$K-\r
+-$L+\r
+-$M-\r
+-$N+\r
+-$O+\r
+-$P+\r
+-$Q-\r
+-$R-\r
+-$S-\r
+-$T-\r
+-$U-\r
+-$V+\r
+-$W-\r
+-$X+\r
+-$YD\r
+-$Z1\r
+-cg\r
+-AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
+-H+\r
+-W+\r
+-M\r
+-$M16384,1048576\r
+-K$00400000\r
+-LE"c:\program files\borland\delphi6\Projects\Bpl"\r
+-LN"c:\program files\borland\delphi6\Projects\Bpl"\r
diff --git a/Chart/Project1.dof b/Chart/Project1.dof
new file mode 100755 (executable)
index 0000000..a4d82b6
--- /dev/null
@@ -0,0 +1,87 @@
+[FileVersion]\r
+Version=6.0\r
+[Compiler]\r
+A=8\r
+B=0\r
+C=1\r
+D=1\r
+E=0\r
+F=0\r
+G=1\r
+H=1\r
+I=1\r
+J=0\r
+K=0\r
+L=1\r
+M=0\r
+N=1\r
+O=1\r
+P=1\r
+Q=0\r
+R=0\r
+S=0\r
+T=0\r
+U=0\r
+V=1\r
+W=0\r
+X=1\r
+Y=1\r
+Z=1\r
+ShowHints=1\r
+ShowWarnings=1\r
+UnitAliases=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;\r
+[Linker]\r
+MapFile=0\r
+OutputObjs=0\r
+ConsoleApp=1\r
+DebugInfo=0\r
+RemoteSymbols=0\r
+MinStackSize=16384\r
+MaxStackSize=1048576\r
+ImageBase=4194304\r
+ExeDescription=\r
+[Directories]\r
+OutputDir=\r
+UnitOutputDir=\r
+PackageDLLOutputDir=\r
+PackageDCPOutputDir=\r
+SearchPath=\r
+Packages=\r
+Conditionals=\r
+DebugSourceDirs=\r
+UsePackages=0\r
+[Parameters]\r
+RunParams=\r
+HostApplication=\r
+Launcher=\r
+UseLauncher=0\r
+DebugCWD=\r
+[Language]\r
+ActiveLang=\r
+ProjectLang=\r
+RootDir=\r
+[Version Info]\r
+IncludeVerInfo=0\r
+AutoIncBuild=0\r
+MajorVer=1\r
+MinorVer=0\r
+Release=0\r
+Build=0\r
+Debug=0\r
+PreRelease=0\r
+Special=0\r
+Private=0\r
+DLL=0\r
+Locale=1033\r
+CodePage=1252\r
+[Version Info Keys]\r
+CompanyName=\r
+FileDescription=\r
+FileVersion=1.0.0.0\r
+InternalName=\r
+LegalCopyright=\r
+LegalTrademarks=\r
+OriginalFilename=\r
+ProductName=\r
+ProductVersion=1.0.0.0\r
+Comments=\r
diff --git a/Chart/Project1.dpr b/Chart/Project1.dpr
new file mode 100755 (executable)
index 0000000..30041d2
--- /dev/null
@@ -0,0 +1,15 @@
+library KFWChart;\r
+\r
+uses\r
+  ComServ;\r
+\r
+exports\r
+  DllGetClassObject,\r
+  DllCanUnloadNow,\r
+  DllRegisterServer,\r
+  DllUnregisterServer;\r
+\r
+{$R *.RES}\r
+\r
+begin\r
+end.\r
diff --git a/Chart/Project1.res b/Chart/Project1.res
new file mode 100755 (executable)
index 0000000..55f8742
Binary files /dev/null and b/Chart/Project1.res differ
diff --git a/Chart/Project1.~dpr b/Chart/Project1.~dpr
new file mode 100755 (executable)
index 0000000..30041d2
--- /dev/null
@@ -0,0 +1,15 @@
+library KFWChart;\r
+\r
+uses\r
+  ComServ;\r
+\r
+exports\r
+  DllGetClassObject,\r
+  DllCanUnloadNow,\r
+  DllRegisterServer,\r
+  DllUnregisterServer;\r
+\r
+{$R *.RES}\r
+\r
+begin\r
+end.\r
diff --git a/Chart/Unit1.dcu b/Chart/Unit1.dcu
new file mode 100755 (executable)
index 0000000..e9ae979
Binary files /dev/null and b/Chart/Unit1.dcu differ
diff --git a/Chart/Unit1.pas b/Chart/Unit1.pas
new file mode 100755 (executable)
index 0000000..7fa7fb2
--- /dev/null
@@ -0,0 +1,394 @@
+unit Unit1;\r
+\r
+{$WARN SYMBOL_PLATFORM OFF}\r
+\r
+interface\r
+\r
+uses\r
+  ComObj, ActiveX, AspTlb, DrawChart_TLB, StdVcl, Windows, Messages, SysUtils, Classes, HTTPApp, variants;\r
+\r
+type\r
+  TDraw = class(TASPMTSObject, IDraw)\r
+  protected\r
+    function Get_Data: WideString; safecall;\r
+    function Get_Height: Integer; safecall;\r
+    function Get_Legend: WordBool; safecall;\r
+    function Get_Stairs: WordBool; safecall;\r
+    function Get_Style: Integer; safecall;\r
+    function Get_Title: WideString; safecall;\r
+    function Get_Values: WideString; safecall;\r
+    function Get_View3d: WordBool; safecall;\r
+    function Get_Width: Integer; safecall;\r
+    function SplitString(Data, Splitter: String): TStringList;\r
+    function setColor(): longint;\r
+    function funcBgColor(): longint;\r
+    function funcWallColor(): longint;\r
+    function Get_Color: WideString; safecall;\r
+    function Get_bgColor: WideString; safecall;\r
+    function Get_wallColor: WideString; safecall;\r
+    procedure Set_Data(const Value: WideString); safecall;\r
+    procedure Set_Height(Value: Integer); safecall;\r
+    procedure Set_Legend(Value: WordBool); safecall;\r
+    procedure Set_Stairs(Value: WordBool); safecall;\r
+    procedure Set_Style(Value: Integer); safecall;\r
+    procedure Set_Title(const Value: WideString); safecall;\r
+    procedure Set_Values(const Value: WideString); safecall;\r
+    procedure Set_View3d(Value: WordBool); safecall;\r
+    procedure Set_Width(Value: Integer); safecall;\r
+    procedure LaLaLa();\r
+    procedure Draw; safecall;\r
+    procedure Set_Color(const Value: WideString); safecall;\r
+    procedure Set_bgColor(const Value: WideString); safecall;\r
+    procedure Set_wallColor(const Value: WideString); safecall;\r
+  end;\r
+\r
+implementation\r
+\r
+uses ComServ, JPEG, Graphics, Chart, Series, Controls, TeEngine;\r
+var\r
+        MainStream      : TMemoryStream;\r
+        inputTitle      : WideString;\r
+        inputWidth      : Integer;\r
+        inputHeight     : Integer;\r
+        inputLegend     : WordBool;\r
+        inputData       : WideString;\r
+        inputValues     : WideString;\r
+        inputStyle      : Integer;\r
+        input3D         : WordBool;\r
+        inputStairs     : WordBool;\r
+        inputColor      : WideString;\r
+        inputWallColor  : WideString;\r
+        inputBgColor    : WideString;\r
+function TDraw.SplitString(Data, Splitter: String): TStringList;\r
+var\r
+        X       : Integer;\r
+begin\r
+        Result := TStringList.Create;\r
+        X := Pos(Splitter, Data);\r
+        while (X > 0) do\r
+        begin\r
+        Result.Add(Copy(Data, 1, X - Length(Splitter)));\r
+        Delete(Data, 1, X + Length(Splitter) -1);\r
+        X := Pos(Splitter, Data);\r
+        end;\r
+        Result.Add(Data);\r
+end;\r
+\r
+function TDraw.setColor(): longint;\r
+begin\r
+        if (inputColor = 'random') OR(inputColor = 'rand') OR (inputColor = '') Then\r
+                begin\r
+                        Result := Random(65536);\r
+                end\r
+        else if (inputColor = 'blue') Then\r
+                begin\r
+                        Result := ColorToRGB(clBlue);\r
+                end\r
+        else if (inputColor = 'green') Then\r
+                begin\r
+                        Result := ColorToRGB(clGreen);\r
+                end\r
+        else if (inputColor = 'red') Then\r
+                begin\r
+                        Result := ColorToRGB(clRed);\r
+                end\r
+        else\r
+                begin\r
+                        Result := ColorToRGB(ColorToRGB(StringToColor(inputColor)));\r
+        end;\r
+end;\r
+\r
+function TDraw.funcBgColor(): longint;\r
+begin\r
+ Result := ColorToRGB(clWhite);\r
+ if inputBgColor = '' Then\r
+ else\r
+ begin\r
+  Result := StringToColor(inputBgColor);\r
+ end;\r
+end;\r
+\r
+function TDraw.funcWallColor(): longint;\r
+begin\r
+ Result := ColorToRGB(clYellow);\r
+ if inputWallColor = '' Then\r
+ else\r
+ begin\r
+  Result := StringToColor(inputWallColor);\r
+ end;\r
+end;\r
+\r
+procedure TDraw.LaLaLa();\r
+        var\r
+                FJPEG   : TJPEGImage;\r
+                Bitmap  : TBitmap;\r
+                i       : Integer;\r
+                FChart  : TChart;\r
+                Rect    : TRect;\r
+                BarSeries       : THorizBarSeries;\r
+                PieSeries       : TPieSeries;\r
+                LineSeries      : TLineSeries;\r
+                vBarSeries      : TBarSeries;\r
+                outputData      : TStringList;\r
+                outputValues    : TStringList;\r
+        begin\r
+                DecimalSeparator := '.';\r
+                Randomize;\r
+                MainStream := TMemoryStream.Create;\r
+                FJPEG := TJPEGImage.Create;\r
+                FChart := TChart.Create(nil);\r
+        try\r
+                // Get the data from the strings\r
+                outputData      := SplitString(inputData, '|');\r
+                outputValues    := SplitString(inputValues, '|');\r
+                // Create The Chart\r
+                FChart.Color    := clWhite;\r
+                FChart.BevelOuter:= bvNone;\r
+                FChart.Legend.Visible := inputLegend;\r
+                FChart.View3D := input3d;\r
+                // Define Size\r
+                Rect.Left       := 0;\r
+                Rect.Top        := 0;\r
+                Rect.Right      := inputWidth;\r
+                Rect.Bottom     := inputHeight;\r
+                if (inputStyle = 4) Then\r
+                begin\r
+                        // Draw the chart\r
+                        PieSeries := TPieSeries.Create(FChart);\r
+                        PieSeries.ParentChart := FChart;\r
+                        PieSeries.ShowInLegend := true;\r
+                        PieSeries.Marks.Style := smsLabelPercent;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 to (outputData.Count -1) do\r
+                        begin\r
+                                PieSeries.AddPie(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(PieSeries);\r
+                end\r
+                else if (inputStyle = 3) then\r
+                begin\r
+                        LineSeries      := TLineSeries.Create(FChart);\r
+                        LineSeries.ParentChart := FChart;\r
+                        LineSeries.ShowInLegend := true;\r
+                        LineSeries.Marks.Style := smsValue;\r
+                        LineSeries.Stairs := inputStairs;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 To (outputData.Count -1) do\r
+                        begin\r
+                        LineSeries.Add(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(LineSeries);\r
+                        end\r
+                else if (inputStyle = 2) then\r
+                begin\r
+                        vBarSeries := TBarSeries.Create(FChart);\r
+                        vBarSeries.BarStyle := bsRectGradient;\r
+                        vBarSeries.ParentChart := FChart;\r
+                        vBarSeries.ShowInLegend := true;\r
+                        vBarSeries.Marks.Style := smsValue;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 To (outputData.Count -1) do\r
+                        begin\r
+                        vBarSeries.AddBar(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(vBarSeries);\r
+                end\r
+                else\r
+                begin\r
+                        BarSeries := THorizBarSeries.Create(FChart);\r
+                        BarSeries.BarStyle := bsRectGradient;\r
+                        BarSeries.ParentChart := FChart;\r
+                        BarSeries.ShowInLegend := true;\r
+                        BarSeries.Marks.Style := smsValue;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 To (outputData.Count -1) do\r
+                        begin\r
+                        BarSeries.AddBar(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(BarSeries);\r
+                end;\r
+                FChart.Legend.TextStyle := ltsRightValue;\r
+                FChart.Title.Font.Size := 10;\r
+                Fchart.Title.Font.Color := clBlack;\r
+                FChart.Title.Text.Clear;\r
+                FChart.Title.Text.Add(inputTitle);\r
+                FChart.LeftWall.Color := funcWallColor();\r
+                FChart.Color := funcBgColor();\r
+                Bitmap := FChart.TeeCreateBitmap(funcBgColor(), Rect);\r
+                // Add the KF Webs text\r
+                // Bitmap.Canvas.TextOut(0, 0, 'Component by Kristian Fiskerstrand - EVALUATION ONLY');\r
+                FJPEG.Assign(bitmap);\r
+                FJPEG.Compress;\r
+                FJPEG.SaveToStream(MainStream);\r
+        finally\r
+        Bitmap.Destroy;\r
+        Bitmap.FreeImage;\r
+        FJPEG.Free;\r
+        FChart.FreeAllSeries;\r
+\r
+        inputWidth      := 250;\r
+        inputHeight     := 250;\r
+        inputLegend     := true;\r
+        inputStyle      := 0;\r
+        input3D         := true;\r
+        inputStairs     := true;\r
+        inputColor      := '';\r
+        inputBgColor    := '';\r
+        inputWallColor  := '';\r
+        outputValues.Free;\r
+        outputData.Free;\r
+        end\r
+end;\r
+\r
+function TDraw.Get_Data: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Height: Integer;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Legend: WordBool;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Stairs: WordBool;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Style: Integer;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Title: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Values: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_View3d: WordBool;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Width: Integer;\r
+begin\r
+\r
+end;\r
+\r
+procedure TDraw.Set_Data(const Value: WideString);\r
+begin\r
+        inputData := value;\r
+end;\r
+\r
+procedure TDraw.Set_Height(Value: Integer);\r
+begin\r
+        inputHeight := value;\r
+end;\r
+\r
+procedure TDraw.Set_Legend(Value: WordBool);\r
+begin\r
+        inputLegend := value;\r
+end;\r
+\r
+procedure TDraw.Set_Stairs(Value: WordBool);\r
+begin\r
+        inputStairs := value;\r
+end;\r
+\r
+procedure TDraw.Set_Style(Value: Integer);\r
+begin\r
+        inputStyle := value;\r
+end;\r
+\r
+procedure TDraw.Set_Title(const Value: WideString);\r
+begin\r
+        inputTitle := value;\r
+end;\r
+\r
+procedure TDraw.Set_Values(const Value: WideString);\r
+begin\r
+        inputValues := value;\r
+end;\r
+\r
+procedure TDraw.Set_View3d(Value: WordBool);\r
+begin\r
+        input3d := value;\r
+end;\r
+\r
+procedure TDraw.Set_Width(Value: Integer);\r
+begin\r
+        inputWidth := value;\r
+end;\r
+\r
+procedure TDraw.Draw;\r
+        var\r
+                v       : OleVariant;\r
+                ptr     : Pointer;\r
+                s       : TMemoryStream;\r
+        begin\r
+                LaLaLa();\r
+                s := MainStream;\r
+                try\r
+                        s.Position := 0;\r
+                        v := VarArrayCreate ( [0, s.Size -1], varByte );\r
+                        ptr := VarArrayLock ( v );\r
+                        try\r
+                                MainStream.ReadBuffer ( ptr^, s.Size );\r
+                        finally\r
+                                VarArrayUnlock ( v );\r
+                        end;\r
+                Response.ContentType := 'image/jpeg';\r
+                Response.BinaryWrite (v);\r
+                Response.Flush;\r
+                finally\r
+                MainStream.Destroy;\r
+                MainStream.Free;\r
+                s.Destroy;\r
+                s.Free;\r
+                end;\r
+end;\r
+\r
+function TDraw.Get_Color: WideString;\r
+begin\r
+\r
+end;\r
+\r
+procedure TDraw.Set_Color(const Value: WideString);\r
+begin\r
+        inputColor := value;\r
+end;\r
+\r
+function TDraw.Get_bgColor: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_wallColor: WideString;\r
+begin\r
+\r
+end;\r
+\r
+procedure TDraw.Set_bgColor(const Value: WideString);\r
+begin\r
+        inputBgColor := value;\r
+end;\r
+\r
+procedure TDraw.Set_wallColor(const Value: WideString);\r
+begin\r
+        inputWallColor := value;\r
+end;\r
+\r
+initialization\r
+  TAutoObjectFactory.Create(ComServer, TDraw, Class_Draw,\r
+    ciMultiInstance, tmApartment);\r
+end.\r
diff --git a/Chart/Unit1.~pas b/Chart/Unit1.~pas
new file mode 100755 (executable)
index 0000000..cfc066a
--- /dev/null
@@ -0,0 +1,396 @@
+unit Unit1;\r
+\r
+{$WARN SYMBOL_PLATFORM OFF}\r
+\r
+interface\r
+\r
+uses\r
+  ComObj, ActiveX, AspTlb, DrawChart_TLB, StdVcl, Windows, Messages, SysUtils, Classes, HTTPApp, variants;\r
+\r
+type\r
+  TDraw = class(TASPMTSObject, IDraw)\r
+  protected\r
+    function Get_Data: WideString; safecall;\r
+    function Get_Height: Integer; safecall;\r
+    function Get_Legend: WordBool; safecall;\r
+    function Get_Stairs: WordBool; safecall;\r
+    function Get_Style: Integer; safecall;\r
+    function Get_Title: WideString; safecall;\r
+    function Get_Values: WideString; safecall;\r
+    function Get_View3d: WordBool; safecall;\r
+    function Get_Width: Integer; safecall;\r
+    function SplitString(Data, Splitter: String): TStringList;\r
+    function setColor(): longint;\r
+    function funcBgColor(): longint;\r
+    function funcWallColor(): longint;\r
+    function Get_Color: WideString; safecall;\r
+    function Get_bgColor: WideString; safecall;\r
+    function Get_wallColor: WideString; safecall;\r
+    procedure Set_Data(const Value: WideString); safecall;\r
+    procedure Set_Height(Value: Integer); safecall;\r
+    procedure Set_Legend(Value: WordBool); safecall;\r
+    procedure Set_Stairs(Value: WordBool); safecall;\r
+    procedure Set_Style(Value: Integer); safecall;\r
+    procedure Set_Title(const Value: WideString); safecall;\r
+    procedure Set_Values(const Value: WideString); safecall;\r
+    procedure Set_View3d(Value: WordBool); safecall;\r
+    procedure Set_Width(Value: Integer); safecall;\r
+    procedure LaLaLa();\r
+    procedure Draw; safecall;\r
+    procedure Set_Color(const Value: WideString); safecall;\r
+    procedure Set_bgColor(const Value: WideString); safecall;\r
+    procedure Set_wallColor(const Value: WideString); safecall;\r
+  end;\r
+\r
+implementation\r
+\r
+uses ComServ, JPEG, Graphics, Chart, Series, Controls, TeEngine;\r
+var\r
+        MainStream      : TMemoryStream;\r
+        inputTitle      : WideString;\r
+        inputWidth      : Integer;\r
+        inputHeight     : Integer;\r
+        inputLegend     : WordBool;\r
+        inputData       : WideString;\r
+        inputValues     : WideString;\r
+        inputStyle      : Integer;\r
+        input3D         : WordBool;\r
+        inputStairs     : WordBool;\r
+        inputColor      : WideString;\r
+        inputWallColor  : WideString;\r
+        inputBgColor    : WideString;\r
+function TDraw.SplitString(Data, Splitter: String): TStringList;\r
+var\r
+        X       : Integer;\r
+begin\r
+        Result := TStringList.Create;\r
+        X := Pos(Splitter, Data);\r
+        while (X > 0) do\r
+        begin\r
+        Result.Add(Copy(Data, 1, X - Length(Splitter)));\r
+        Delete(Data, 1, X + Length(Splitter) -1);\r
+        X := Pos(Splitter, Data);\r
+        end;\r
+        Result.Add(Data);\r
+end;\r
+\r
+function TDraw.setColor(): longint;\r
+begin\r
+        if (inputColor = 'random') OR(inputColor = 'rand') OR (inputColor = '') Then\r
+                begin\r
+                        Result := Random(65536);\r
+                end\r
+        else if (inputColor = 'blue') Then\r
+                begin\r
+                        Result := ColorToRGB(clBlue);\r
+                end\r
+        else if (inputColor = 'green') Then\r
+                begin\r
+                        Result := ColorToRGB(clGreen);\r
+                end\r
+        else if (inputColor = 'red') Then\r
+                begin\r
+                        Result := ColorToRGB(clRed);\r
+                end\r
+        else\r
+                begin\r
+                        Result := ColorToRGB(ColorToRGB(StringToColor(inputColor)));\r
+        end;\r
+end;\r
+\r
+function TDraw.funcBgColor(): longint;\r
+begin\r
+ Result := ColorToRGB(clWhite);\r
+ if inputBgColor = '' Then\r
+ else\r
+ begin\r
+  Result := StringToColor(inputBgColor);\r
+ end;\r
+end;\r
+\r
+function TDraw.funcWallColor(): longint;\r
+begin\r
+ Result := ColorToRGB(clYellow);\r
+ if inputWallColor = '' Then\r
+ else\r
+ begin\r
+  Result := StringToColor(inputWallColor);\r
+ end;\r
+end;\r
+\r
+procedure TDraw.LaLaLa();\r
+        var\r
+                FJPEG   : TJPEGImage;\r
+                Bitmap  : TBitmap;\r
+                i       : Integer;\r
+                FChart  : TChart;\r
+                Rect    : TRect;\r
+                BarSeries       : THorizBarSeries;\r
+                PieSeries       : TPieSeries;\r
+                LineSeries      : TLineSeries;\r
+                vBarSeries      : TBarSeries;\r
+                outputData      : TStringList;\r
+                outputValues    : TStringList;\r
+        begin\r
+                DecimalSeparator := '.';\r
+                Randomize;\r
+                MainStream := TMemoryStream.Create;\r
+                FJPEG := TJPEGImage.Create;\r
+                FChart := TChart.Create(nil);\r
+        try\r
+                // Get the data from the strings\r
+                outputData      := SplitString(inputData, '|');\r
+                outputValues    := SplitString(inputValues, '|');\r
+                // Create The Chart\r
+                FChart.Color    := clWhite;\r
+                FChart.BevelOuter:= bvNone;\r
+                FChart.Legend.Visible := inputLegend;\r
+                FChart.View3D := input3d;\r
+                // Define Size\r
+                Rect.Left       := 0;\r
+                Rect.Top        := 0;\r
+                Rect.Right      := inputWidth;\r
+                Rect.Bottom     := inputHeight;\r
+                if (inputStyle = 4) Then\r
+                begin\r
+                        // Draw the chart\r
+                        PieSeries := TPieSeries.Create(FChart);\r
+                        PieSeries.ParentChart := FChart;\r
+                        PieSeries.ShowInLegend := true;\r
+                        PieSeries.Marks.Style := smsLabelPercent;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 to (outputData.Count -1) do\r
+                        begin\r
+                                PieSeries.AddPie(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(PieSeries);\r
+                end\r
+                else if (inputStyle = 3) then\r
+                begin\r
+                        LineSeries      := TLineSeries.Create(FChart);\r
+                        LineSeries.ParentChart := FChart;\r
+                        LineSeries.ShowInLegend := true;\r
+                        LineSeries.Marks.Style := smsValue;\r
+                        LineSeries.Stairs := inputStairs;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 To (outputData.Count -1) do\r
+                        begin\r
+                        LineSeries.Add(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(LineSeries);\r
+                        end\r
+                else if (inputStyle = 2) then\r
+                begin\r
+                        vBarSeries := TBarSeries.Create(FChart);\r
+                        vBarSeries.BarStyle := bsRectGradient;\r
+                        vBarSeries.ParentChart := FChart;\r
+                        vBarSeries.ShowInLegend := true;\r
+                        vBarSeries.Marks.Style := smsValue;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 To (outputData.Count -1) do\r
+                        begin\r
+                        vBarSeries.AddBar(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(vBarSeries);\r
+                end\r
+                else\r
+                begin\r
+                        BarSeries := THorizBarSeries.Create(FChart);\r
+                        BarSeries.BarStyle := bsRectGradient;\r
+                        BarSeries.ParentChart := FChart;\r
+                        BarSeries.ShowInLegend := true;\r
+                        BarSeries.Marks.Style := smsValue;\r
+                        FChart.SeriesList.Clear;\r
+                        for i := 0 To (outputData.Count -1) do\r
+                        begin\r
+                        BarSeries.AddBar(StrToFloat(StringReplace(outputValues[i], ',', '.', [rfReplaceAll])), outputData[i], setColor());\r
+                        end;\r
+                        FChart.SeriesList.Add(BarSeries);\r
+                end;\r
+                FChart.Legend.TextStyle := ltsRightValue;\r
+                FChart.Title.Font.Size := 10;\r
+                Fchart.Title.Font.Color := clBlack;\r
+                FChart.Title.Text.Clear;\r
+                FChart.Title.Text.Add(inputTitle);\r
+                FChart.LeftWall.Color := funcWallColor();\r
+                FChart.Color := funcBgColor();\r
+                Bitmap := FChart.TeeCreateBitmap(funcBgColor(), Rect);\r
+                // Add the KF Webs text\r
+                // Bitmap.Canvas.TextOut(0, 0, 'Component by Kristian Fiskerstrand - EVALUATION ONLY');\r
+                FJPEG.Assign(bitmap);\r
+                FJPEG.Compress;\r
+                FJPEG.SaveToStream(MainStream);\r
+        finally\r
+        Bitmap.Destroy;\r
+        Bitmap.FreeImage;\r
+        FJPEG.Free;\r
+        FChart.FreeAllSeries;\r
+\r
+        inputWidth      := 250;\r
+        inputHeight     := 250;\r
+        inputLegend     := true;\r
+        inputStyle      := 0;\r
+        input3D         := true;\r
+        inputStairs     := true;\r
+        inputColor      := '';\r
+        inputBgColor    := '';\r
+        inputWallColor  := '';\r
+        outputValues.Destroy;\r
+        outputValues.Free;\r
+        outputData.Destroy;\r
+        outputData.Free;\r
+        end\r
+end;\r
+\r
+function TDraw.Get_Data: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Height: Integer;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Legend: WordBool;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Stairs: WordBool;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Style: Integer;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Title: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Values: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_View3d: WordBool;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_Width: Integer;\r
+begin\r
+\r
+end;\r
+\r
+procedure TDraw.Set_Data(const Value: WideString);\r
+begin\r
+        inputData := value;\r
+end;\r
+\r
+procedure TDraw.Set_Height(Value: Integer);\r
+begin\r
+        inputHeight := value;\r
+end;\r
+\r
+procedure TDraw.Set_Legend(Value: WordBool);\r
+begin\r
+        inputLegend := value;\r
+end;\r
+\r
+procedure TDraw.Set_Stairs(Value: WordBool);\r
+begin\r
+        inputStairs := value;\r
+end;\r
+\r
+procedure TDraw.Set_Style(Value: Integer);\r
+begin\r
+        inputStyle := value;\r
+end;\r
+\r
+procedure TDraw.Set_Title(const Value: WideString);\r
+begin\r
+        inputTitle := value;\r
+end;\r
+\r
+procedure TDraw.Set_Values(const Value: WideString);\r
+begin\r
+        inputValues := value;\r
+end;\r
+\r
+procedure TDraw.Set_View3d(Value: WordBool);\r
+begin\r
+        input3d := value;\r
+end;\r
+\r
+procedure TDraw.Set_Width(Value: Integer);\r
+begin\r
+        inputWidth := value;\r
+end;\r
+\r
+procedure TDraw.Draw;\r
+        var\r
+                v       : OleVariant;\r
+                ptr     : Pointer;\r
+                s       : TMemoryStream;\r
+        begin\r
+                LaLaLa();\r
+                s := MainStream;\r
+                try\r
+                        s.Position := 0;\r
+                        v := VarArrayCreate ( [0, s.Size -1], varByte );\r
+                        ptr := VarArrayLock ( v );\r
+                        try\r
+                                MainStream.ReadBuffer ( ptr^, s.Size );\r
+                        finally\r
+                                VarArrayUnlock ( v );\r
+                        end;\r
+                Response.ContentType := 'image/jpeg';\r
+                Response.BinaryWrite (v);\r
+                Response.Flush;\r
+                finally\r
+                MainStream.Destroy;\r
+                MainStream.Free;\r
+                s.Destroy;\r
+                s.Free;\r
+                end;\r
+end;\r
+\r
+function TDraw.Get_Color: WideString;\r
+begin\r
+\r
+end;\r
+\r
+procedure TDraw.Set_Color(const Value: WideString);\r
+begin\r
+        inputColor := value;\r
+end;\r
+\r
+function TDraw.Get_bgColor: WideString;\r
+begin\r
+\r
+end;\r
+\r
+function TDraw.Get_wallColor: WideString;\r
+begin\r
+\r
+end;\r
+\r
+procedure TDraw.Set_bgColor(const Value: WideString);\r
+begin\r
+        inputBgColor := value;\r
+end;\r
+\r
+procedure TDraw.Set_wallColor(const Value: WideString);\r
+begin\r
+        inputWallColor := value;\r
+end;\r
+\r
+initialization\r
+  TAutoObjectFactory.Create(ComServer, TDraw, Class_Draw,\r
+    ciMultiInstance, tmApartment);\r
+end.\r
diff --git a/DrawChart.asp b/DrawChart.asp
new file mode 100755 (executable)
index 0000000..3b5707c
--- /dev/null
@@ -0,0 +1,15 @@
+<%
+ Option Explicit
+ ' Requirements
+ ' Requires the KF Webs DrawChart Component - DrawChart.dll, this can be found by contacting KF Webs - http://kf.ma.cx
+ ' Register it using regsvr32 c:\DrawChart.dll
+ Dim objChart
+ Set objChart = Server.CreateObject("DrawChart.Draw")
+  objChart.Width = 400
+  objChart.Height = 400
+  objChart.Title = "Just a test"
+  objChart.Data = "Test1|Test2|Test3|Test4|Test5|Test6"
+  objChart.Values = "1|2|3|4|5|6"
+  objChart.Draw()
+ Set objChart = Nothing
+%>
diff --git a/DrawChart.dll b/DrawChart.dll
new file mode 100755 (executable)
index 0000000..b5769b8
Binary files /dev/null and b/DrawChart.dll differ