本文整理汇总了C#中TableRow.AddClass方法的典型用法代码示例。如果您正苦于以下问题:C# TableRow.AddClass方法的具体用法?C# TableRow.AddClass怎么用?C# TableRow.AddClass使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TableRow
的用法示例。
在下文中一共展示了TableRow.AddClass方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: CreateAttributeRow
private TableRow CreateAttributeRow(string concept, string code, string codeDesc, bool highlighted = false)
{
TableRow tr = new TableRow();
if (highlighted) tr.AddClass(HtmlClasses.ExtraInfoTableRowHighlighted);
TableCell cell_concept = new TableCell(concept);
cell_concept.AddClass(HtmlClasses.ExtraInfoTableLabelConcept);
TableCell cell_concept_value = new TableCell(string.Format("[{0}] - {1}", code, codeDesc));
cell_concept_value.AddClass(HtmlClasses.ExtraInfoTableLabelConceptValue);
tr.AddCell(cell_concept);
tr.AddCell(cell_concept_value);
return tr;
}
示例2: CreateVerticalTitles
/// <summary>
/// Create and setup the titles for vertical dimensions
/// </summary>
/// <param name="model">
/// The DataSetModel to use
/// </param>
/// <returns>
/// The row with the titles
/// </returns>
private TableRow CreateVerticalTitles(IDataSetModel model)
{
var verticalTitles = new TableRow();
verticalTitles.AddClass(HtmlClasses.VerticalKeys);
foreach (string dim in model.VerticalKeys)
{
TableCell tableCell = this.CreateTitle(model.AllValidKeys[dim], dim, HtmlClasses.VerticalKeyTitle);
// new TD();
verticalTitles.AddElement(tableCell);
}
return verticalTitles;
}
示例3: CreateContainerTable
/// <summary>
/// Create the container table. The container table holds the slice header and slice data tables.
/// </summary>
/// <returns>
/// The table that holds the slice header and data
/// </returns>
private static Table CreateContainerTable()
{
var containerTable = new Table();
containerTable.AddClass(HtmlClasses.Container);
containerTable.AddAttribute(HtmlConstants.CellPadding, ZeroValue);
containerTable.AddAttribute(HtmlConstants.CellSpacing, ZeroValue);
var sliceRow = new TableRow();
containerTable.AddElement(sliceRow);
var skeys = new TableCell();
skeys.AddClass(HtmlClasses.SliceKeys);
sliceRow.AddElement(skeys);
var hvkeys = new TableRow(new TableCell());
hvkeys.AddClass(HtmlClasses.HorizontalVerticalKeys);
containerTable.AddElement(hvkeys);
return containerTable;
}
示例4: CreateHorizontalTitles
/// <summary>
/// Create and setup the titles for horizontal dimensions
/// </summary>
/// <param name="model">
/// The DataSetModel to use
/// </param>
/// <param name="horizontalRows">
/// The horizontal map to add the titles to
/// </param>
/// <param name="horizontalOrderedRows">
/// The list of rows
/// </param>
private void CreateHorizontalTitles(
IDataSetModel model,
IDictionary<string, TableRow> horizontalRows,
ICollection<TableRow> horizontalOrderedRows)
{
foreach (string dim in model.HorizontalKeys)
{
var row = new TableRow();
row.AddClass(HtmlClasses.HorizontalKeys);
// First cell is the title, which spawns over all columns used for vertical keys...
TableCell tableCell = this.CreateTitle(model.AllValidKeys[dim], dim, "hkeytitle");
tableCell.SetColSpan(Math.Max(1, model.VerticalKeys.Count));
row.AddCell(tableCell);
horizontalRows.Add(dim, row);
horizontalOrderedRows.Add(row);
}
}