unity生成pdf格式,首先需要导入iTextSharp.dll ,下面是我写的一些方法,可以直接用.直接贴代码,

using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using iTextSharp.text.pdf;
using iTextSharp.text;
using System.Text.RegularExpressions;
using System.Data.OracleClient;
using System; //需要用到的数据结构
public class PdfUserInformation
{
public string goodsName;
public string youzhanType;
public string cvsLevel;
public string writeTime;
public string creater;
public string creatTime;
};
//数据结构
public class PdfInformation
{
public string mID;
public string mName;
public string mReserve;
// ....
}; public class PDFMakerManager { public static PDFMakerManager PDFInstance;
public static PDFMakerManager createPDFMakerManager()
{
if(PDFInstance==null)
{
PDFInstance = new PDFMakerManager ();
} return PDFInstance;
} //获取物品的子物体名字 通过子物体的名字获取物体 返回物体的链表
public List<PdfInformation> getObjChildsName(Transform mParentObj)
{ if(mParentObj!=null)
{
List<string> mChildObjs = new List<string>();
List<PdfInformation> mInfoList = new List<PdfInformation>();
foreach (Transform mChildTransform in mParentObj)
{
mChildObjs.Add(mChildTransform.gameObject.name);
Debug.Log(mChildTransform.gameObject.name);
}
//获取 数据库 信息
getPdfDatasFromDB();
//通过子物体的名字 获取物体信息
for (int i = 0; i < mChildObjs.Count; i++)
{
mInfoList.Add(mDirectoryData[mChildObjs[i]]);
}
return mInfoList;
}
return null;
}
//每行五个 还有问题,由于需求以及时间关系,没时间去管了 谁看到了可以帮忙解决下,.thanks
List<PdfInformation> mGoodsInfoList = new List<PdfInformation>();
public List<List<PdfInformation>> getAllGoods(List<PdfInformation> mList)
{
List<List<PdfInformation>> mGoodsAll = new List<List<PdfInformation>>();
List<List<PdfInformation>> mGoods = new List<List<PdfInformation>>(); for (int i = 1; i <= mList.Count;i++ )
{
mGoodsInfoList.Add(mList[i-1]); if(i%5==0)
{ mGoodsAll.Add(mGoodsInfoList);
Debug.Log("xx"+mGoodsInfoList.Count);
mGoodsInfoList.Clear(); for (int j = 0; j < mGoodsAll.Count; j++)
{
Debug.Log("InfoList [[[" + j + "]]]is:" + mGoodsAll[j].Count);
} }else if(i%5!=0&&i==mList.Count)
{
mGoodsAll.Add(mGoodsInfoList);
mGoodsInfoList.Clear();
}
}
Debug.Log("InfoList [[[is:" + mGoodsAll.Count);
//for (int j = 0; j < mGoodsAll.Count;j++ )
//{
// Debug.Log("InfoList [[[" + j + "]]]is:" + mGoodsAll[j].Count);
//} return mGoodsAll;
}
//从数据库 获取 PDF 信息
Dictionary<string, PdfInformation> mDirectoryData = new Dictionary<string, PdfInformation>();
public List<PdfInformation> getPdfDatasFromDB()
{
List<PdfInformation> mInfoList = new List<PdfInformation>(); Oracle mDB = new Oracle ();
try
{
string mSearch = "select * from mdb";
mInfoList = mDB.Select(mSearch);
mDirectoryData = mDB.getPdfDictionary();
}catch(Exception e)
{
mDB.Close();
Debug.Log("sql error");
}
return mInfoList;
} // / pdf 行
public PdfPTable CreateRankGoodsInforMationTable(List<List<PdfInformation>> mList)
{
PdfPTable mTable=new PdfPTable(1); mTable.SetTotalWidth(new float[]{300}); mTable.HorizontalAlignment = PdfPTable.LINECANVAS; if(mList.Count>0)
{
for(int i=0;i<mList.Count;i++)
{
Debug.Log("xx"+i+"xxxxxx:"+mList[i].Count);
// mTable.AddCell(CreateCell(CreateRowGoodsInforMationTable2(mList[i]),-1,0));
} } mTable.LockedWidth = true;
return mTable;
}
//
//pdf 列
PdfPTable CreateRowGoodsInforMationTable2(System.Collections.Generic.List<PdfInformation> mList)
{
PdfPTable mTable =new PdfPTable (mList.Count);
System.Collections.Generic.List<float> Width = new System.Collections.Generic.List<float> ();
if(mList.Count>0)
{
for(int i=0;i<mList.Count;i++)
{
Width.Add(80f);
}
}
float []mWidth = Width.ToArray();
mTable.HorizontalAlignment = PdfPTable.BACKGROUNDCANVAS; if (mWidth[0] != -1)
{
mTable.SetTotalWidth(mWidth);
}
mTable.LockedWidth = true;
for(int i=0;i<mList.Count;i++)
{ mTable.AddCell(CreateGoodsInformationCell(mList[i]));
}
mList.Clear();
return mTable;
} //pdf 图 暂时没用
byte[] GoodsImgPrint(Camera SmallCamera,GameObject TakeHuoJia)
{
int swidth = (int)(SmallCamera.WorldToScreenPoint(TakeHuoJia.transform.position + TakeHuoJia.renderer.bounds.size).x - SmallCamera.WorldToScreenPoint(TakeHuoJia.transform.position - TakeHuoJia.renderer.bounds.size).x); RenderTexture rt = new RenderTexture(Screen.width, resHeight, 72);
SmallCamera.pixelRect = new Rect(0, 0, Screen.width, Screen.height);
SmallCamera.targetTexture = rt;
Texture2D screenShot = new Texture2D(swidth + 100, resHeight, TextureFormat.ARGB32, false);
SmallCamera.Render();
RenderTexture.active = rt; screenShot.ReadPixels(new Rect(SmallCamera.WorldToScreenPoint(TakeHuoJia.transform.position - TakeHuoJia.renderer.bounds.size).x, 0, swidth + 100, resHeight), 0, 0);
screenShot.Apply();
SmallCamera.targetTexture = null;
RenderTexture.active = null; //
UnityEngine.Object.Destroy(rt);
byte[] bytes = screenShot.EncodeToPNG(); return bytes;
}
//打印物品详细信息 图 (左边字 右边图 分开的 ,写法一:pdf字和摄像头图)
public void PrintGoodsInformations2(string filePath, Camera mCam, GameObject mObj, PdfUserInformation mInfo)
{
Document document = new Document(new Rectangle(PageSize.A4.Height, PageSize.A4.Width));
PdfWriter.GetInstance(document, new FileStream(filePath, FileMode.Create));
document.Open(); PdfPTable tableAll = tableAll = CreateTable(2, PdfPTable.BACKGROUNDCANVAS, new float[] { document.PageSize.Width / 2 - 50, document.PageSize.Width / 2 - 50 }, true);
//
PdfPTable tableLeft = PrintGoodsInformations_Left(mInfo); Image tableRight = MakeCameraImg(mCam, 512, 512);//Image.GetInstance( GoodsImgPrint(mCam,mObj)); tableAll.AddCell(CreateCell(tableLeft, -1, 0));
tableAll.AddCell(CreateCell(tableRight, -1, 0));
document.Add(tableAll);
document.Close();
ShowTips.showTips(" 打印完成!文件保存在:" + filePath);
}
//打印物品详细信息 图 (左边字 右边图 分开的 ,写法2:摄像头全图,包括字和图)
public void PrintGoodsInformations(string filePath, Camera mCam,GameObject mObj,PdfUserInformation mInfo)
{
Document document = new Document(new Rectangle(PageSize.A4.Height, PageSize.A4.Width));
PdfWriter.GetInstance(document, new FileStream(filePath, FileMode.Create));
document.Open(); PdfPTable tableAll = CreateTable(1, PdfPTable.BACKGROUNDCANVAS, new float[] {document.PageSize.Width -100 }, true);
//
PdfPTable tableLeft = PrintGoodsInformations_Left(mInfo); Image tableRight = MakeCameraImg(mCam,680,512);//Image.GetInstance( GoodsImgPrint(mCam,mObj)); // tableAll.AddCell(CreateCell(tableLeft, -1, 0));
tableAll.AddCell(CreateCell(tableRight, -1, 0));
document.Add(tableAll);
document.Close();
ShowTips.showTips(" 打印完成!文件保存在:" + filePath);
} //打印物品详细信息 左边字 右边字
public void PrintGoodsInformations(string filePath,PdfUserInformation mInfo)
{
Document document = new Document(new Rectangle(PageSize.A4.Height,PageSize.A4.Width));
PdfWriter.GetInstance(document,new FileStream(filePath,FileMode.Create));
document.Open(); PdfPTable tableAll = CreateTable(2, PdfPTable.BACKGROUNDCANVAS, new float[] { document.PageSize.Width / 2 - 50, document.PageSize.Width / 2 - 50 }, true);
//
PdfPTable tableLeft = PrintGoodsInformations_Left(mInfo); //测试数据 ....
PdfInformation mInfo1 = new PdfInformation();
mInfo1.mName = "aaaa";
PdfInformation mInfo2 = new PdfInformation();
mInfo2.mName = "bbbbb"; List<PdfInformation> mInfoList = new List<PdfInformation>();
mInfoList.Add(mInfo1);
mInfoList.Add(mInfo2); PdfInformation mInfo3 = new PdfInformation();
mInfo3.mName = "ccccc";
PdfInformation mInfo4 = new PdfInformation();
mInfo4.mName = "ddddd"; List<PdfInformation> mInfoList2 = new List<PdfInformation>();
mInfoList2.Add(mInfo3);
mInfoList2.Add(mInfo4); List<List<PdfInformation>> mLLInfo = new List<List<PdfInformation>>();
mLLInfo.Add(mInfoList);
mLLInfo.Add(mInfoList2); //....... //测试数据 数据库数据
// List<List<PdfInformation>> mDBTestList = new List<List<PdfInformation>>();
//mDBTestList = getAllGoods(getPdfDatasFromDB()); //Debug.Log("DBList is:"+mDBTestList.Count);
//...... PdfPTable tableRight = CreateRankGoodsInforMationTable(mDBTestList);
tableRight.HorizontalAlignment = PdfPTable.BACKGROUNDCANVAS;
tableAll.AddCell(CreateCell(tableLeft, -1, 0));
tableAll.AddCell(CreateCell(tableRight,-1,0));
document.Add(tableAll);
document.Close();
ShowTips.showTips(" 打印完成!文件保存在:" + filePath); }
//详细信息的左半部分
PdfPTable PrintGoodsInformations_Left(PdfUserInformation mInfo)
{
PdfPTable tableHeaderR = CreateTable(1, PdfPTable.BACKGROUNDCANVAS, new float[] { -1 }, false);
PdfPTable tableHeaderminiR = CreateTable(2, PdfPTable.BACKGROUNDCANVAS, new float[] { 1, 3 }, false); Image mark = Image.GetInstance(Application.dataPath + "/Icon.png");
mark.ScaleAbsolute(250, 250);
mark.Alignment = Image.LEFT_BORDER;
tableHeaderminiR.AddCell(CreateCell(mark, 2, 0));//<<<<<<<<< //tableHeaderminiR.AddCell(CreateCell("商品", -1, 0, CreateFont(32, iTextSharp.text.Font.NORMAL)));//<<<<<<<<
tableHeaderminiR.AddCell(CreateCell("标题", -1, 0, CreateFont(32, iTextSharp.text.Font.NORMAL)));//<<<<<<<<
tableHeaderminiR.AddCell(CreateCell("xxx", -1, 0, CreateFont(22, iTextSharp.text.Font.NORMAL)));//<<<<<<<< PdfPTable tableDataR = CreateTable(1, PdfPTable.BACKGROUNDCANVAS, new float[] { 350 }, true);
tableDataR.AddCell(CreateCell("\n", -1, 0, CreateFont(12, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell("名称:\n", -1, -1, CreateFont(22, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell(mInfo.goodsName, -1, -1, CreateFont(20, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell("类型:\n", -1, -1, CreateFont(22, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell(mInfo.youzhanType, -1, -1, CreateFont(20, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell("级别:\n", -1, -1, CreateFont(22, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell(mInfo.cvsLevel, -1, -1, CreateFont(20, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell("时间:\n", -1, -1, CreateFont(22, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell(mInfo.writeTime, -1, -1, CreateFont(20, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell("创建者:", -1, -1, CreateFont(22, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell(mInfo.creater, -1, -1, CreateFont(20, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell("创建时间:\n", -1, -1, CreateFont(22, iTextSharp.text.Font.NORMAL)));
tableDataR.AddCell(CreateCell(mInfo.creatTime, -1, -1, CreateFont(20, iTextSharp.text.Font.NORMAL)));
tableHeaderR.AddCell(CreateCell(tableHeaderminiR, -1, 0));//<<<<<<<<
tableHeaderR.AddCell(CreateCell(tableDataR, -1, 0)); return tableHeaderR;
} //把摄像头视野 制作成png图片
private Rect CutRect = new Rect(0, 0, 1, 1);
private int resWidth = 710;
private int resHeight = 512;
private Image MakeCameraImg(Camera mCam,int width,int height)
{
Image mImage;
RenderTexture rt = new RenderTexture(width, height, 2);
mCam.pixelRect = new Rect(0, 0, Screen.width, Screen.height);
mCam.targetTexture = rt;
Texture2D screenShot = new Texture2D((int)(width * CutRect.width), (int)(height * CutRect.height),
TextureFormat.RGB24, false);
mCam.Render();
RenderTexture.active = rt;
screenShot.ReadPixels(new Rect(width * CutRect.x, width * CutRect.y, width * CutRect.width, height * CutRect.height), 0, 0);
mCam.targetTexture = null;
RenderTexture.active = null;
UnityEngine.Object.Destroy(rt);
byte[] bytes = screenShot.EncodeToPNG();
//string filename = Application.dataPath + "/Print/3D"
// + System.DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss") + ".png";
//System.IO.File.WriteAllBytes(filename, bytes); mImage = Image.GetInstance(bytes);
return mImage; }
//打印图片 (摄像头视野看到的/生成的图片) 成PDF
public void PrintImgPdf(string filePath, Camera mCam)
{
Document document = new Document(new Rectangle(PageSize.A4.Height, PageSize.A4.Width));
PdfWriter.GetInstance(
document,
new FileStream(filePath, FileMode.Create)
); document.Open();
Image imge;
imge = MakeCameraImg(mCam,700,512);
PdfPTable tableAll = CreateTable(1, PdfPTable.BACKGROUNDCANVAS, new float[] { document.PageSize.Width -50}, true);
PdfPTable tableHeaderR = CreateTable(1, PdfPTable.BACKGROUNDCANVAS, new float[] { -1 }, false);
PdfPTable tableHeaderminiR = CreateTable(1, PdfPTable.BACKGROUNDCANVAS, new float[] { 1 }, false);
//
Image mark = imge;
mark.ScaleAbsolute(mark.Width, mark.Height);
mark.Alignment = Image.LEFT_BORDER;
tableHeaderminiR.AddCell(CreateCell(mark, 2, 0));//<<<<<<<<< tableHeaderR.AddCell(CreateCell(tableHeaderminiR, -1, 0));//<<<<<<<<
tableAll.AddCell(CreateCell(tableHeaderR, -1, 0));//<<<<<<<< document.Add(tableAll);
document.Close();
ShowTips.showTips(" 打印完成!文件保存在:" + filePath); }
public PdfPTable CreateTable(int numCol, int HorizontalAlignmentStyle, float[] Width, bool isLockedWidth)
{
PdfPTable tableAll = new PdfPTable(numCol);
tableAll.HorizontalAlignment = HorizontalAlignmentStyle;
if (Width[0] != -1)
{
tableAll.SetTotalWidth(Width);
}
tableAll.LockedWidth = isLockedWidth;
return tableAll;
} public PdfPCell CreateCell(PdfPTable table, int rowspan, int borderStyle)
{
PdfPCell cell = new PdfPCell(table);
if (borderStyle != -1 && borderStyle >= 0)
{
cell.Border = borderStyle;
}
if (rowspan != -1)
{
cell.Rowspan = rowspan;
} cell.HorizontalAlignment = PdfPCell.ALIGN_LEFT;
cell.VerticalAlignment = PdfPCell.ALIGN_LEFT | PdfPCell.ALIGN_CENTER;
return cell;
} public PdfPCell CreateCell(Image image, int rowspan, int borderStyle)
{
PdfPCell cell = new PdfPCell(image);
if (borderStyle != -1 && borderStyle >= 0)
{
cell.Border = borderStyle;
}
if (rowspan != -1)
{
cell.Rowspan = rowspan;
}
cell.HorizontalAlignment = PdfPCell.ALIGN_LEFT;
cell.VerticalAlignment = PdfPCell.ALIGN_BASELINE;
return cell;
} public PdfPCell CreateCell(string text, int rowspan, int borderStyle, iTextSharp.text.Font cellFont)
{
PdfPCell cell = new PdfPCell(new Phrase(text, cellFont));
if (borderStyle != -1 && borderStyle>=0)
{
cell.Border = borderStyle;
}
if (rowspan != -1)
{
cell.Rowspan = rowspan;
} cell.HorizontalAlignment = PdfPCell.ALIGN_LEFT;
cell.VerticalAlignment = PdfPCell.ALIGN_CENTER;
return cell;
}
/// <summary> 只在详细信息的时候用
PdfPCell CreateGoodsInformationCell(PdfInformation mInfo)
{ string text = mInfo.mName +"\n";
iTextSharp.text.Font font =CreateFont(20, iTextSharp.text.Font.NORMAL);
PdfPCell cell = new PdfPCell(new Phrase(text,font));
cell.HorizontalAlignment = PdfPCell.ALIGN_LEFT;
cell.VerticalAlignment = PdfPCell.ALIGN_LEFT; return cell; }
/// </param>/ public void CellAddTable(PdfPCell cell,PdfPTable table)
{
cell.AddElement(table);
}
public iTextSharp.text.Font CreateFont(float fontSize, int fontStyle)
{
BaseFont bfChinese = BaseFont.CreateFont( Application.dataPath + "/font/MSYH.TTF",
BaseFont.IDENTITY_H,
BaseFont.NOT_EMBEDDED ); return new iTextSharp.text.Font(bfChinese, fontSize, fontStyle);
} }

下面是调用:

using UnityEngine;
using System.Collections; public class PrintPdf : MonoBehaviour { //需要将这几个摄像头绑定对应的
PDFMakerManager mPdfManager;
public Camera m3DCamera;
public Camera mHightCam;
public GameObject mObj;
public Camera mInfoCamera;
string mPdfPath; public GameObject[] Texts = new GameObject[6];
public string[] Textstext;
PdfUserInformation mPDFUserInfo;
// Use this for initialization
void Start () { Textstext = new string[6];
mPdfManager = new PDFMakerManager();
mPDFUserInfo = new PdfUserInformation(); } // Update is called once per frame
void Update () { } void OnGUI()
{ if (GUI.Button(new Rect(100, 100, 100, 40), "PdfInfoPrint"))
{ PrintInfoPdf();
}
if (GUI.Button(new Rect(300, 100, 100, 40), "PdfInfoImgPrint"))
{ PrintInfoImgPdf();
}
if (GUI.Button(new Rect(400, 100, 100, 40), "PdfHightPrint"))
{
PrintHightImgPdf();
}
} // 还需要把摄像头绑定对
// 把写字的物体绑定对
// 在 调用函数 需要 找对 位置
public void getText()
{
for (int i = 0; i < Texts.Length; i++)
{
Textstext[i] = Texts[i].GetComponent<UILabel>().text;
}
mPDFUserInfo.goodsName = Textstext[0];
mPDFUserInfo.youzhanType = Textstext[1];
mPDFUserInfo.cvsLevel = Textstext[2];
mPDFUserInfo.writeTime = Textstext[3];
mPDFUserInfo.creater = Textstext[4];
mPDFUserInfo.creatTime = Textstext[5]; }
//打印 左边字 右边表格
public void PrintInfoPdf()
{
getText();
mPdfManager.PrintGoodsInformations(mPdfPath,mPDFUserInfo);
}
//打印 信息 图片
public void PrintInfoImgPdf()
{ getText();
mPdfPath = Application.dataPath + "/Print/InfoImg"
+ System.DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss") + ".pdf"; mPdfManager.PrintGoodsInformations(mPdfPath, mInfoCamera, mObj, mPDFUserInfo); } //打印 图
public void PrintHightImgPdf()
{
mPdfPath = Application.dataPath + "/Print/Top"
+ System.DateTime.Now.ToString("yyyy-MM-dd_HH-mm-ss") + ".pdf";
mPdfManager.PrintImgPdf(mPdfPath, mHightCam); }
}

注:如需转载,请注明出处,

unity3d导出pdf的更多相关文章

  1. .Net导出pdf文件,C#实现pdf导出

    最近碰见个需求需要实现导出pdf文件,上网查了下代码资料总结了以下代码.可以成功的实现导出pdf文件. 在编码前需要在网上下载个itextsharp.dll,此程序集是必备的.楼主下载的是5.0版本, ...

  2. GJM :Unity3d导出eclipse工程,导入Android Studio

    unity3d导出eclipse工程,导入Android Studio 标签: unity3Dandroid studio 2016-08-11 10:42 398人阅读 评论(1) 收藏 举报 分类 ...

  3. JS导出PDF插件(支持中文、图片使用路径)

    在WEB上想做一个导出PDF的功能,发现jsPDF比较多人推荐,遗憾的是不支持中文,最后找到pdfmake,很好地解决了此问题.它的效果可以先到http://pdfmake.org/playgroun ...

  4. ITextSharp导出PDF表格和图片(C#)

    文章主要介绍使用ITextSharp导出PDF表格和图片的简单操作说明,以下为ITextSharp.dll下载链接 分享链接:http://pan.baidu.com/s/1nuc6glj 密码:3g ...

  5. JAVA导出pdf实例

    一.直接导出成PDF   Java代码 1. import java.io.FileNotFoundException; 2. import java.io.FileOutputStream; 3.  ...

  6. 利用ITextSharp导出PDF文件

    最近项目中需要到处PDF文件,最后上网搜索了一下,发现ITextSharp比较好用,所以做了一个例子: public string ExportPDF() { //ITextSharp Usage / ...

  7. iText导出pdf、word、图片

    一.前言 在企业的信息系统中,报表处理一直占比较重要的作用,本文将介绍一种生成PDF报表的Java组件--iText.通过在服务器端使用Jsp或JavaBean生成PDF报表,客户端采用超级连接显示或 ...

  8. Itext导出PDF,word,图片案例

    iText导出pdf.word.图片 一.前言 在企业的信息系统中,报表处理一直占比较重要的作用,本文将介绍一种生成PDF报表的Java组件--iText.通过在服务器端使用Jsp或JavaBean生 ...

  9. Ireport 报表导出 Poi + ireport 导出pdf, word ,excel ,htm

    Ireport 报表导出 Poi + ireport 导出pdf, doc ,excel ,html 格式 下面是报表导出工具类reportExportUtils 需要导出以上格式的报表 只需要调用本 ...

随机推荐

  1. java设计模式--创建模式--原型模式

    原型模式: 原型模式 概述 用原型实例指定创建对象的种类,并且通过拷贝这些原型创建新的对象. 适用性 .当一个系统应该独立于它的产品创建.构成和表示时. .当要实例化的类是在运行时刻指定时,例如,通过 ...

  2. SSIS 系列 - 在 SSIS 中使用 Multicast Task 将数据源数据同时写入多个目标表,备份数据表,以及写入Audit 信息

    转自http://www.cnblogs.com/biwork/p/3328838.html 在 SSIS Data Flow 中有一个 Multicast 组件,它的作用和 Merge, Merge ...

  3. LeeCode-Roman to Integer

    Given a roman numeral, convert it to an integer. Input is guaranteed to be within the range from 1 t ...

  4. openstack API debug OpenstackEveryProject_CLI,curl_based

    1,基于Openstack 每个服务组件client客户端,eg,nova 客户端软件包名称是python-novaclient, 别的都一样,把python-novaclient (nova替换成组 ...

  5. javax.Swing 使用GridBagLayout的程序栗子

    摘自https://zhidao.baidu.com/question/110748776.html javax.Swing 使用GridBagLayout的程序栗子 总共两个文件,第一个是启动文件, ...

  6. 俄罗斯方块:win32api开发

    本文简述一门课程,演示win32api开发俄罗斯方块的开发过程.如果学生学习过C语言,没学过或者学习C++不好,刚刚開始学习win32api程序设计,还不懂消息循环和注冊窗体类.   近期的照片在这里 ...

  7. [Python] 发送email的几种方式

    python发送email还是比較简单的,能够通过登录邮件服务来发送,linux下也能够使用调用sendmail命令来发送,还能够使用本地或者是远程的smtp服务来发送邮件,无论是单个,群发,还是抄送 ...

  8. css3动画学习的例子来源

    1.这里面有不同的鼠标经过图片效果,图片变大变小,出现文字,向左移动等等 http://dinolatoga.com/demo/webkit-image-hover-effects/ 2.有一篇博客, ...

  9. 如何在美国公司写project plan 邮件--以hadoop安装和Mahout数据分析为例子

    Hi, XXX (boss name) Project Title:  Hadoop installation and Data analysis based on Mahout Deliverabl ...

  10. Xcode5 配置 github

    首先,要在github上,进行如下的操作: 1. github 官网 https://github.com  注册github账号. 2. 创建一个repository,命名为项目的名称,如 Gith ...