BioInt
1.02.00
BioInt: An integrative biological object-oriented application framework and interpreter
|
00001 #ifndef BIOHTML_H 00002 #define BIOHTML_H 00003 00004 #include <fstream> 00005 #include "BioData.h" 00006 00007 using namespace std; 00008 00009 class BioHtml : public ofstream 00010 { 00011 string fn_,txt_,fgcolor_,align_,font_,bgcolor_; 00012 string fillSpace(string st); 00013 int flag; 00014 00015 public : 00016 BioHtml(); 00017 BioHtml(const string&); 00018 ~BioHtml(); 00019 void setHeading(string txt_,int size = 1); 00020 void setPageTitle(string title="NULL"); 00021 void setHyperLink(string txt, string url); 00022 void setFile(const string&); 00023 void setBold(bool); 00024 void setItalic(bool); 00025 void setUnderLine(bool); 00026 void setFont(string fontName_); 00027 void setFontClose(); 00028 void setAlign(string align_); 00029 void setBreakLine(); 00030 void setFontSize(int size); 00031 void setFontSizeClose(); 00032 void setImage(string img_="NULL",int width=0,int height=0, string alt_="NULL"); 00033 void setBackgroundColor(string bgColor_); 00034 void setFontColor(string fgColor_); 00035 void setFontColorClose(); 00036 string getRGBColor(int r,int g,int b); 00037 void addText(string txt_); 00038 void setStyleBegin(string fontName_ = "Verdana",int fontSize=11,string bgcolor_="white",string fgcolor= "black",bool bold_=0, bool italic_=0,string align_ = "LEFT"); 00039 void setStyleEnd(); 00040 void setBlockBegin(string fontName_ = "Verdana",int fontSize=11,string bgcolor_="white",string fgcolor= "black",bool bold_=0, bool italic_=0,int width = 650,int height=0); 00041 void setBlockEnd(); 00042 void BioHtmlClose(); 00043 00044 void setTableBegin (string align_="CENTER", int border_=1, int width_=800, int height_=0, string bg_="lightgrey"); 00045 void setRowBegin(); 00046 void setRowEnd(); 00047 void setColumnBegin(int width_=0,int heigt_=0, int mergeRows_=1, int mergeCols_=1); 00048 void setColumnEnd(); 00049 00050 void setColumn(string txt_,int mergeRows_=1, int mergeCols_=1,int width_=0); 00051 void setTableEnd(); 00052 00053 00054 void showGraph(BioData data,int col = 0,const string & caption = "NULL",bool asItIs_=0); 00055 void showGraph(vector <long> vl,vector <string> vst,const string & cap = "NULL",bool asItIs_=0); 00056 void showGraph(vector <double> vd,vector <string> vst,const string & cap = "NULL",bool asItIs_=0); 00057 00058 void showGraph(vector <int> vd,vector <string> vst,const string & cap = "NULL",bool asItIs_=0); 00059 void showGraph(vector <int> vl, const string & cap = "NULL",bool asItIs_=0); 00060 00061 void showGraph(vector <long> vl, const string & cap = "NULL",bool asItIs_=0); 00062 void showGraph(vector <double> vd, const string & cap = "NULL",bool asItIs_=0); 00063 00064 void showMultipleGraphs(vector <BioData> vst, vector<string>,bool asItIs_=0); 00065 }; 00066 #endif