本文整理汇总了C#中iTextSharp.text.Table.EndHeaders方法的典型用法代码示例。如果您正苦于以下问题:C# Table.EndHeaders方法的具体用法?C# Table.EndHeaders怎么用?C# Table.EndHeaders使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类iTextSharp.text.Table
的用法示例。
在下文中一共展示了Table.EndHeaders方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: EscrevaProcessosNoDocumentoSintetico
private void EscrevaProcessosNoDocumentoSintetico()
{
var tabela = new Table(4);
tabela.Widths = new Single[] { 60, 100, 60, 100 };
tabela.Padding = 1;
tabela.Spacing = 0;
tabela.Width = 100;
tabela.AutoFillEmptyCells = true;
var corBackgroudHeader = new Color(211, 211, 211);
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Número do processo", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Marca", _Fonte2, Cell.ALIGN_LEFT, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Despacho", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Cliente", _Fonte2, Cell.ALIGN_LEFT, 0, corBackgroudHeader, true));
tabela.EndHeaders();
foreach (var processo in _processos)
{
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Processo.ToString(), _Fonte1, Cell.ALIGN_CENTER, 0, false));
if (processo.Marca != null && !string.IsNullOrEmpty(processo.Marca.DescricaoDaMarca))
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Marca.DescricaoDaMarca, _Fonte1, Cell.ALIGN_LEFT, 0, false));
else
tabela.AddCell(iTextSharpUtilidades.CrieCelula(string.Empty, _Fonte1, Cell.ALIGN_LEFT, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Despacho != null ? processo.Despacho.CodigoDespacho : "", _Fonte1, Cell.ALIGN_CENTER, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Marca.Cliente.Pessoa.Nome, _Fonte1, Cell.ALIGN_LEFT, 0, false));
}
_documento.Add(tabela);
}
开发者ID:ViniciusConsultor,项目名称:petsys,代码行数:36,代码来源:GeradorDeRelatorioDeProcessosDeMarcasPublicacoesProprias.cs
示例2: EscrevaProcessosNoDocumentoAnalitico
private void EscrevaProcessosNoDocumentoAnalitico()
{
var tabela = new Table(6);
tabela.Widths = new Single[] { 60, 100, 50, 100, 60, 100 };
tabela.Padding = 0;
tabela.Spacing = 0;
tabela.Width = 100;
tabela.AutoFillEmptyCells = true;
tabela.EndHeaders();
foreach (var processo in _processos)
{
var labelNumeroProcesso =
new Cell(new Phrase("Número do processo: ", _Fonte2));
labelNumeroProcesso.DisableBorderSide(0);
tabela.AddCell(labelNumeroProcesso);
var valorNumeroProcesso =
new Cell(new Phrase(processo.Processo.ToString(), _Fonte1));
valorNumeroProcesso.DisableBorderSide(0);
tabela.AddCell(valorNumeroProcesso);
var labelDataDoCadastro = new Cell(new Phrase("Data do cadastro: ", _Fonte2));
labelDataDoCadastro.DisableBorderSide(0);
tabela.AddCell(labelDataDoCadastro);
var valorDataDoCadastro = new Cell(new Phrase(processo.DataDoCadastro.ToString("dd/MM/yyyy"), _Fonte1));
valorDataDoCadastro.DisableBorderSide(0);
tabela.AddCell(valorDataDoCadastro);
var labelDespacho = new Cell(new Phrase("Despacho: ", _Fonte2));
labelDespacho.DisableBorderSide(0);
tabela.AddCell(labelDespacho);
var valorDespacho = processo.Despacho != null ? new Cell(new Phrase(processo.Despacho.CodigoDespacho, _Fonte1)) :
new Cell(new Phrase(string.Empty, _Fonte1));
valorDespacho.DisableBorderSide(0);
tabela.AddCell(valorDespacho);
var labelApresentacao = new Cell(new Phrase("Apresentação: ", _Fonte2));
labelApresentacao.DisableBorderSide(0);
tabela.AddCell(labelApresentacao);
Cell valorApresentacao;
if(processo.Marca != null && processo.Marca.Apresentacao != null)
valorApresentacao = new Cell(new Phrase(processo.Marca.Apresentacao.Nome, _Fonte1));
else
valorApresentacao = new Cell(new Phrase(string.Empty, _Fonte1));
valorApresentacao.DisableBorderSide(0);
tabela.AddCell(valorApresentacao);
var labelNatureza = new Cell(new Phrase("Natureza: ", _Fonte2));
labelNatureza.DisableBorderSide(0);
tabela.AddCell(labelNatureza);
Cell valorNatureza;
if (processo.Marca != null && processo.Marca.Natureza != null)
valorNatureza = new Cell(new Phrase(processo.Marca.Natureza.Nome, _Fonte1));
else
valorNatureza = new Cell(new Phrase(string.Empty, _Fonte1));
valorNatureza.DisableBorderSide(0);
tabela.AddCell(valorNatureza);
var labelNCL = new Cell(new Phrase("NCL: ", _Fonte2));
labelNCL.DisableBorderSide(0);
tabela.AddCell(labelNCL);
Cell valorNCL;
if (processo.Marca != null && processo.Marca.NCL != null)
valorNCL = new Cell(new Phrase(processo.Marca.NCL.Codigo, _Fonte1));
else
valorNCL = new Cell(new Phrase(string.Empty, _Fonte1));
//.........这里部分代码省略.........
开发者ID:ViniciusConsultor,项目名称:petsys,代码行数:101,代码来源:GeradorDeRelatorioDeProcessosDeMarcasPublicacoesProprias.cs
示例3: Download_Click
protected void Download_Click(object sender, EventArgs e)
{
// Check condition
if (!GridView1.Columns[GridView1.Columns.Count - 1].Visible)
{
// Create PDF Document
String Path = Server.MapPath("~\\Bangdiem\\DKHP\\DKHP_" + userName + ".pdf");
Document myDocument = new Document(PageSize.A4, 5, 5, 30, 10);
if (!File.Exists(Path))
{
PdfWriter.GetInstance(myDocument, new FileStream(Path, FileMode.CreateNew));
// Open document
myDocument.Open();
BaseFont bf = BaseFont.CreateFont(Server.MapPath(@"~\Font\TIMES.TTF"), BaseFont.IDENTITY_H, true);
iTextSharp.text.Font font = new iTextSharp.text.Font(bf, 12);
iTextSharp.text.Image image = iTextSharp.text.Image.GetInstance(Server.MapPath("~/images/UIT.png"));
image.Alignment = iTextSharp.text.Image.UNDERLYING;
image.ScaleToFit(30f, 30f);
Chunk c1 = new Chunk("TRƯỜNG ĐẠI HỌC CÔNG NGHỆ THÔNG TIN", font);
c1.SetUnderline(0.5f, -4f);
Paragraph Header = new Paragraph(15);
Header.IndentationLeft = 15;
Header.Alignment = 3;
Header.Font = font;
Header.Add(image);
Header.SpacingBefore = 5f;
Header.Add(" ĐẠI HỌC QUỐC GIA THÀNH PHỐ HỒ CHÍ MINH \n ");
Header.Add(c1);
Header.Add("\n\n\n");
myDocument.Add(Header);
// Add gridview to
iTextSharp.text.Table table = new iTextSharp.text.Table(5);
// set table style properties
table.BorderWidth = 1;
table.BorderColor = Color.DARK_GRAY;
table.Padding = 4;
table.Alignment = 1;
table.Width = 90;
// set *column* widths
float[] widths = { 0.05f, 0.23f, 0.17f, 0.45f, 0.1f };
table.Widths = widths;
string[] col = { "TT", "Mã Lớp", "Mã Môn", "Tên Môn Học", "Số TC" };
font = new iTextSharp.text.Font(bf, 13, 1);
// create the *table* header row
for (int i = 0; i < col.Length; ++i)
{
Cell cell = new Cell(new Phrase(col[i], font));
cell.Header = true;
cell.HorizontalAlignment = 1;
table.AddCell(cell);
}
table.EndHeaders();
int sum = 0;
font = new iTextSharp.text.Font(bf, 12);
int order = 0;
foreach (GridViewRow row in GridView1.Rows)
{
Cell c = new Cell(new Phrase((++order).ToString(), font));
c.HorizontalAlignment = 1;
table.AddCell(c);
c = new Cell(new Phrase(row.Cells[1].Text, font));
c.HorizontalAlignment = 1;
table.AddCell(c);
c = new Cell(new Phrase(((HiddenField)row.FindControl("SubID")).Value, font));
c.HorizontalAlignment = 1;
table.AddCell(c);
c = new Cell(new Phrase(" " + ((LinkButton)row.FindControl("SubNm")).Text, font));
table.AddCell(c);
c = new Cell(new Phrase(row.Cells[3].Text, font));
c.HorizontalAlignment = 1;
try { sum += Int16.Parse(row.Cells[3].Text); }
catch (Exception ex) { }
table.AddCell(c);
}
font = new iTextSharp.text.Font(bf, 14);
Paragraph p = new Paragraph("ĐĂNG KÍ HỌC PHẦN HK " + getTerm() + " " + getYear() + " \n", font);
p.Alignment = 1;
p.Add("MSSV : " + userName);
myDocument.Add(p);
font = new iTextSharp.text.Font(bf, 12);
//.........这里部分代码省略.........
示例4: GenerateXMLReport
public void GenerateXMLReport()
{
try
{
this.doc.Open();
RenderLogo();
//RenderHeaderAddress();
RenderReportJobInfo();
RenderProjectsReports();
#region Add Details Table
float[] DetailsHeaderwidths = this.Headerwidths; // percentage
iTextSharp.text.Table JobDetailstable = new iTextSharp.text.Table(DetailsHeaderwidths.Length);
JobDetailstable.Padding = 1;
JobDetailstable.DefaultCell.BorderWidth = 1;
JobDetailstable.Widths = DetailsHeaderwidths;
JobDetailstable.WidthPercentage = 100;
JobDetailstable.DefaultCell.HorizontalAlignment = Element.ALIGN_CENTER;
JobDetailstable.DefaultCell.BackgroundColor = Color.LIGHT_GRAY;
foreach (var x in this.ColList)
{
JobDetailstable.AddCell(new Phrase(x, fntHeading));
}
JobDetailstable.EndHeaders();
Font myDetailFont = fntDetails;
foreach (var x in this.ReportRows)
{
for (int i = 0; i < ColList.Count; i++)
{
JobDetailstable.DefaultCell.BackgroundColor = Color.WHITE;
if(x.row[i].type == CellType.Number)
JobDetailstable.DefaultCell.HorizontalAlignment = Element.ALIGN_RIGHT;
else
JobDetailstable.DefaultCell.HorizontalAlignment = Element.ALIGN_LEFT;
JobDetailstable.AddCell(new Phrase(x.row[i].value, myDetailFont));
}
}
JobDetailstable.DefaultCell.HorizontalAlignment = Element.ALIGN_LEFT;
Cell cell = new Cell(new Paragraph("Total", myDetailFont));
cell.BackgroundColor = Color.LIGHT_GRAY;
cell.BorderWidth = 1;
cell.Colspan = 3;
JobDetailstable.AddCell(cell);
JobDetailstable.DefaultCell.HorizontalAlignment = Element.ALIGN_RIGHT;
JobDetailstable.DefaultCell.BackgroundColor = Color.LIGHT_GRAY;
JobDetailstable.AddCell(new Phrase(this.total, myDetailFont));
doc.Add(JobDetailstable);
#endregion
}
catch (Exception ex)
{
//MessageBox.Show("Error: " + ex.Message);
}
doc.Close();
writer.Close();
}
示例5: GenerateXMLReport
public void GenerateXMLReport()
{
try
{
this.doc.Open();
RenderLogo();
RenderDescription();
RenderReportJobInfo();
iTextSharp.text.Table myTable = new iTextSharp.text.Table(ColList.Count);
myTable.Widths = this.Headerwidths;
myTable.WidthPercentage = 100;
//myTable.Locked = true;
//Render Table Headers~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
myTable.DefaultLayout.HorizontalAlignment = Element.ALIGN_LEFT;
myTable.DefaultCell.BorderWidth = ReportBorderWidth;
myTable.Cellpadding = 1;
myTable.DefaultCell.VerticalAlignment = Element.ALIGN_MIDDLE;
myTable.DefaultCell.HorizontalAlignment = Element.ALIGN_CENTER;
myTable.DefaultCell.BackgroundColor = Color.LIGHT_GRAY;
myTable.DefaultCell.UseBorderPadding = true;
foreach (var x in this.ColList)
{
myTable.AddCell(new Phrase(x, fntHeading));
}
myTable.EndHeaders();
//Render Details~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Font myDetailFont = fntDetails;
foreach (var x in this.ReportRows)
{
for (int i = 0; i < ColList.Count; i++)
{
myTable.DefaultCell.BackgroundColor = Color.WHITE;
if (x.row[i].type == CellType.Number)
myTable.DefaultCell.HorizontalAlignment = Element.ALIGN_RIGHT;
else
myTable.DefaultCell.HorizontalAlignment = Element.ALIGN_LEFT;
if (i > ColList.Count - 3)
myTable.DefaultCell.BackgroundColor = Color.LIGHT_GRAY;
else
myTable.DefaultCell.BackgroundColor = Color.WHITE;
if (i == ColList.Count - 3)
myTable.AddCell(new Phrase(x.row[i].value, footerFont));
else
myTable.AddCell(new Phrase(x.row[i].value, myDetailFont));
}
}
//Footer Totals~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
myTable.DefaultCell.HorizontalAlignment = Element.ALIGN_RIGHT;
myTable.DefaultCell.BackgroundColor = Color.WHITE;
myTable.DefaultCell.Colspan = 4;
myTable.AddCell(new Phrase("Totals", footerFont));
myTable.DefaultCell.Colspan = 1;
for (int i = 4; i < FooterList.Count; i++)
{
myTable.AddCell(new Phrase(FooterList[i], footerFont));
//if ((FooterList[i].Length > 0 && SacoList[i].Length > 0) && (decimal.Parse(FooterList[i]) > decimal.Parse(SacoList[i])))
//{
// myTable.AddCell(new Phrase(FooterList[i], ErrorFont));
//}
//else
//{
// if (SacoList[i].Trim().Length == 0)
// myTable.AddCell(new Phrase(FooterList[i], ErrorFont));
// else
// myTable.AddCell(new Phrase(FooterList[i], footerFont));
//}
}
//Render Saco Totals~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
myTable.DefaultCell.HorizontalAlignment = Element.ALIGN_RIGHT;
myTable.DefaultCell.BackgroundColor = Color.BLUE;
myTable.DefaultCell.Colspan = 4;
myTable.AddCell(new Phrase("Saco Hours", SacoFont));
myTable.DefaultCell.Colspan = 1;
for (int i = 4; i < SacoList.Count; i++)
{
myTable.AddCell(new Phrase(SacoList[i], SacoFont));
}
//Render Diff Totals~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
myTable.DefaultCell.HorizontalAlignment = Element.ALIGN_RIGHT;
myTable.DefaultCell.BackgroundColor = Color.WHITE;
//.........这里部分代码省略.........
示例6: GeneratePDF
protected void GeneratePDF()
{
// Refresh the grid else there will be nothing to generate (no postback)
this.PopulateGrid();
// Create and initialize a new document object
iTextSharp.text.Document document = new iTextSharp.text.Document(iTextSharp.text.PageSize.LEGAL, 24, 24, 24, 24);
document.PageSize.Rotate();
System.IO.MemoryStream memoryStream = new System.IO.MemoryStream();
try
{
// Create an instance of the writer object
iTextSharp.text.pdf.PdfWriter writer = iTextSharp.text.pdf.PdfWriter.GetInstance(document, memoryStream);
// Add some meta information to the document
Label lblPageTitle = (Label)(this.Page.Master.FindControl("lblDefaultMasterPageTitle"));
document.AddAuthor(lblPageTitle.Text);
document.AddSubject(this.lblReportTitle.Text);
// Open the document
document.Open();
// Create a table to match our current summary grid
iTextSharp.text.Table table = new iTextSharp.text.Table(4);
table.TableFitsPage = true;
// Apply spacing/padding/borders/column widths to the table
table.Padding = 2;
table.Spacing = 0;
table.DefaultCellBorderWidth = 1;
float[] headerwidths = { 40, 30, 30, 35 };
table.Widths = headerwidths;
table.Width = 100;
// Add report title spanning all columns
iTextSharp.text.Font titleFont = new iTextSharp.text.Font(Font.GetFamilyIndex("Tahoma"), 4, Font.BOLD);
titleFont.Color = new iTextSharp.text.Color(System.Drawing.Color.Firebrick);
iTextSharp.text.Cell titleCell = new iTextSharp.text.Cell();
titleCell.SetHorizontalAlignment("Left");
titleCell.SetVerticalAlignment("Top");
titleCell.BackgroundColor = new iTextSharp.text.Color(System.Drawing.Color.White);
titleCell.BorderWidth = 0;
titleCell.Colspan = 4;
titleCell.AddElement(new iTextSharp.text.Phrase(this.lblReportTitle.Text, titleFont));
table.AddCell(titleCell);
// Add table headers
for (int i = 0; i < this.grdReporting.Columns.Count; i++)
{
iTextSharp.text.Font headerCellFont = new iTextSharp.text.Font(Font.GetFamilyIndex("Tahoma"), 8, Font.NORMAL + Font.UNDERLINE);
headerCellFont.Color = new iTextSharp.text.Color(System.Drawing.Color.White);
iTextSharp.text.Cell headerCell = new iTextSharp.text.Cell();
headerCell.SetHorizontalAlignment("Left");
headerCell.SetVerticalAlignment("Top");
headerCell.BackgroundColor = new iTextSharp.text.Color(System.Drawing.Color.SteelBlue);
headerCell.BorderColor = new iTextSharp.text.Color(System.Drawing.Color.White);
headerCell.AddElement(new iTextSharp.text.Phrase(this.grdReporting.Columns[i].HeaderText, headerCellFont));
table.AddCell(headerCell);
}
table.EndHeaders();
// Add data to the table
int j = 0;
int k = 0;
string phrase = "";
foreach (System.Data.DataRow row in this._pdfDataTable.Rows)
{
j++; // Increment the row counter
k = 0; // Reset the column counter for the new row
foreach (System.Data.DataColumn col in this._pdfDataTable.Columns)
{
k++; // Increment the column counter
iTextSharp.text.Font cellFont = new iTextSharp.text.Font(Font.GetFamilyIndex("Tahoma"), 7, Font.NORMAL);
if (j % 2 == 0)
{
cellFont.Color = new iTextSharp.text.Color(System.Drawing.Color.DarkRed);
}
else
{
cellFont.Color = new iTextSharp.text.Color(System.Drawing.Color.Black);
}
iTextSharp.text.Cell cell = new iTextSharp.text.Cell();
cell.SetHorizontalAlignment("Left");
cell.SetVerticalAlignment("Top");
cell.BorderColor = new iTextSharp.text.Color(System.Drawing.Color.White);
if (j % 2 == 0)
{
//.........这里部分代码省略.........
示例7: EscrevaProcessosNoDocumento
private void EscrevaProcessosNoDocumento()
{
Table tabela = new Table(9);
tabela.Widths = new Single[] {100, 100, 100, 100, 100, 400, 400, 90, 85};
tabela.Padding = 1;
tabela.Spacing = 0;
tabela.Width = 100;
tabela.AutoFillEmptyCells = true;
var corBackgroudHeader = new Color(211, 211, 211);
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Número do processo", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Data do cadastro", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Data do depósito", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Data de concessão", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Data da vigência", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Marca", _Fonte2, Cell.ALIGN_LEFT, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Cliente", _Fonte2, Cell.ALIGN_LEFT, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Despacho", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Ativo?", _Fonte2, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.EndHeaders();
foreach (var processo in _processos)
{
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Processo.ToString(), _Fonte1, Cell.ALIGN_CENTER,0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.DataDoCadastro.ToString("dd/MM/yyyy"), _Fonte1, Cell.ALIGN_CENTER, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.DataDoDeposito.HasValue ? processo.DataDoDeposito.Value.ToString("dd/MM/yyyy") : "", _Fonte1, Cell.ALIGN_CENTER, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.DataDeConcessao.HasValue ? processo.DataDeConcessao.Value.ToString("dd/MM/yyyy") : "", _Fonte1, Cell.ALIGN_CENTER, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.DataDaVigencia.HasValue ? processo.DataDaVigencia.Value.ToString("dd/MM/yyyy") : "", _Fonte1, Cell.ALIGN_CENTER, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Marca.DescricaoDaMarca, _Fonte1, Cell.ALIGN_LEFT,0 , false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Marca.Cliente.Pessoa.Nome, _Fonte1, Cell.ALIGN_LEFT, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Despacho != null ? processo.Despacho.CodigoDespacho.ToString() : "", _Fonte1, Cell.ALIGN_CENTER, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Ativo ? "SIM" : "NÃO", _Fonte1, Cell.ALIGN_CENTER, 0, false));
}
_documento.Add(tabela);
// Chunk linhaQuantidadeDeItens = new Chunk(String.Concat("Quantidade de processos de marcas : ", _processos.Count), _Fonte4);
// _documento.Add(linhaQuantidadeDeItens);
}
示例8: EscrevaProcessosNoDocumentoAnalitico
private void EscrevaProcessosNoDocumentoAnalitico()
{
var tabela = new Table(1);
tabela.Widths = new Single[] { 218 };
tabela.Padding = 0;
tabela.Spacing = 0;
tabela.Width = 100;
tabela.AutoFillEmptyCells = true;
tabela.DefaultCell.Border = Rectangle.NO_BORDER;
tabela.EndHeaders();
foreach (var revistaDePatente in _revistasPatentes)
{
var tabela1 = new Table(1);
tabela1.Widths = new Single[] { 100 };
tabela1.Padding = 0;
tabela1.Spacing = 0;
tabela1.Width = 100;
tabela1.AutoFillEmptyCells = true;
tabela1.Border = 0;
tabela1.EndHeaders();
tabela1.DefaultCell.Border = Rectangle.NO_BORDER;
var tabelaProcesso = new Cell(ObtenhaTabelaCelulaProcesso(revistaDePatente));
tabela1.AddCell(tabelaProcesso);
var tabelaRevistas = new Cell(ObtenhaTabelaInformacoesRevista(revistaDePatente));
tabela1.AddCell(tabelaRevistas);
tabela.AddCell(new Cell(tabela1));
tabela.AddCell(ObtenhaCelulaVazia());
tabela.AddCell(ObtenhaCelulaVazia());
tabela.AddCell(ObtenhaCelulaVazia());
}
_documento.Add(tabela);
}
示例9: ObtenhaTabelaInformacoesRevista
private Table ObtenhaTabelaInformacoesRevista(IRevistaDePatente revista)
{
var tabela = new Table(1);
tabela.Widths = new Single[] { 100 };
tabela.Padding = 0;
tabela.Spacing = 0;
tabela.Width = 100;
tabela.AutoFillEmptyCells = true;
tabela.Border = 0;
tabela.EndHeaders();
if(revista.DataPublicacao.HasValue && revista.DataPublicacao.Value != DateTime.MinValue)
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout43.IdentificadorCampo + " " + revista.DataPublicacao.Value.ToString("dd/MM/yyyy"), _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (revista.DataDeDeposito.HasValue && revista.DataDeDeposito.Value != DateTime.MinValue)
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout22.IdentificadorCampo + " " + revista.DataDeDeposito.Value.ToString("dd/MM/yyyy"), _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.NumeroProcessoDaPatente))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout11.IdentificadorCampo + " " + revista.NumeroProcessoDaPatente, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.NumeroDoPedido))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout21.IdentificadorCampo + " " + revista.NumeroDoProcessoFormatado, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (revista.DataDaPublicacaoDoPedido.HasValue && revista.DataDaPublicacaoDoPedido.Value != DateTime.MinValue)
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout43.IdentificadorCampo + " " + revista.DataDaPublicacaoDoPedido.Value.ToString("dd/MM/yyyy"), _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (revista.DataDeConcessao.HasValue && revista.DataDeConcessao.Value != DateTime.MinValue)
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout45.IdentificadorCampo + " " + revista.DataDeConcessao.Value.ToString("dd/MM/yyyy"), _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.PrioridadeUnionista))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout43.IdentificadorCampo + " " + revista.DataPublicacao.Value.ToString("dd/MM/yyyy"), _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.ClassificacaoInternacional))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout51.IdentificadorCampo + " " + revista.ClassificacaoInternacional, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.Titulo))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout54.IdentificadorCampo + " " + revista.Titulo, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.Resumo))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout57.IdentificadorCampo + " " + revista.Resumo, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.DadosDoPedidoDaPatente))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout61.IdentificadorCampo + " " + revista.DadosDoPedidoDaPatente, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.DadosDoPedidoOriginal))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout62.IdentificadorCampo + " " + revista.DadosDoPedidoOriginal, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
}
if (!string.IsNullOrEmpty(revista.PrioridadeInterna))
{
var celula = new Cell(new Phrase(" " + LayoutRevistaPatente.Layout66.IdentificadorCampo + " " + revista.PrioridadeInterna, _Fonte1));
celula.DisableBorderSide(0);
tabela.AddCell(celula);
//.........这里部分代码省略.........
示例10: ObtenhaTabelaCelulaProcesso
private Table ObtenhaTabelaCelulaProcesso(IRevistaDePatente revista)
{
var tabela = new Table(1);
var corBackgroudHeader = new Color(211, 211, 211);
tabela.Widths = new Single[] { 100 };
tabela.Padding = 0;
tabela.Spacing = 0;
tabela.Width = 100;
tabela.AutoFillEmptyCells = true;
tabela.Border = 0;
tabela.EndHeaders();
var celula1 = new Cell(new Phrase("Processo " + revista.NumeroDoProcessoFormatado, _Fonte3));
celula1.DisableBorderSide(0);
celula1.BackgroundColor = corBackgroudHeader;
tabela.AddCell(celula1);
return tabela;
}
示例11: EscrevaProcessosNoDocumentoSintetico
private void EscrevaProcessosNoDocumentoSintetico()
{
var tabela = new Table(4);
tabela.Widths = new Single[] { 60, 100, 60, 100 };
tabela.Padding = 1;
tabela.Spacing = 0;
tabela.Width = 100;
tabela.AutoFillEmptyCells = true;
tabela.DefaultCell.Border = Rectangle.NO_BORDER;
var corBackgroudHeader = new Color(211, 211, 211);
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Número do processo", _Fonte3, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Patente", _Fonte3, Cell.ALIGN_LEFT, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Despacho", _Fonte3, Cell.ALIGN_CENTER, 0, corBackgroudHeader, true));
tabela.AddCell(iTextSharpUtilidades.CrieCelula("Cliente", _Fonte3, Cell.ALIGN_LEFT, 0, corBackgroudHeader, true));
tabela.EndHeaders();
foreach (var processo in _processosPatentes)
{
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.NumeroDoProcessoFormatado.ToString(), _Fonte1, Cell.ALIGN_CENTER, 0, false));
if (processo.Patente != null && !string.IsNullOrEmpty(processo.Patente.TituloPatente))
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Patente.TituloPatente, _Fonte1, Cell.ALIGN_LEFT, 0, false));
else
tabela.AddCell(iTextSharpUtilidades.CrieCelula(string.Empty, _Fonte1, Cell.ALIGN_LEFT, 0, false));
tabela.AddCell(iTextSharpUtilidades.CrieCelula(processo.Despacho != null ? processo.Despacho.Codigo : "", _Fonte1, Cell.ALIGN_CENTER, 0, false));
string clientes = string.Empty;
if (processo.Patente != null)
{
clientes = processo.Patente.Clientes.Aggregate(clientes, (current, cliente) => current + (cliente.Pessoa.Nome + " - "));
if (!string.IsNullOrEmpty(clientes))
clientes = clientes.Substring(0, clientes.Length - 3);
}
tabela.AddCell(iTextSharpUtilidades.CrieCelula(clientes, _Fonte1, Cell.ALIGN_LEFT, 0, false));
}
_documento.Add(tabela);
}