Toggle menu
875
3.8K
30.2K
279.1K
Catglobe Wiki
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

TabulationBulletNumeric class: Difference between revisions

From Catglobe Wiki
Nguyenduyan (talk | contribs)
No edit summary
Nguyenduyan (talk | contribs)
No edit summary
Line 23: Line 23:
bulletNum.Level = 1;//Defines what level of the list we want the paragraph.  
bulletNum.Level = 1;//Defines what level of the list we want the paragraph.  
bulletNum.Color = Color_getByName("green");
bulletNum.Color = Color_getByName("green");
bulletNum.IsInList = true;//Defines if the bullet point is in a list.
bulletNum.StartNumber = 1;//The number the list should start with. Must only be set for the first element.  
bulletNum.StartNumber = 1;//The number the list should start with. Must only be set for the first element.  
bulletNum.IsPrefixed = false; //Indicates if the list in the pdf shoud prefix the number with higher levels ie: true: 1.1.2. false: 2.
bulletNum.IsPrefixed = false; //Indicates if the list in the pdf shoud prefix the number with higher levels ie: true: 1.1.2. false: 2.


TabulationParagraphStyle paragraphStyle = new TabulationParagraphStyle();
paragraphStyle.SetBulletSetting(bulletNum);
paragraphStyle.SetBulletSetting(bulletNum);
Tabulation_addParagraph(new TabulationParagraph(paragraphStyle,"A numbered list item",textStyle));</source>
paragraphStyle.Alignment = "center"; //left, right, center.
paragraphStyle.MarginTopPoints = 10; //0-400
paragraphStyle.MarginLeftPoints = 10;//0-400
 
TabulationTextStyle textStyle = new TabulationTextStyle();
textStyle.Color = Color_getByName("red"); //Takes a color array-
//textStyle.Color = Color_getByRGB(255,0,0); // can also be set from rgb.
//textStyle.Color = new Color("red",false); // can also be set by Color object
textStyle.FontFace = "Bariol Regular";
textStyle.FontSize = 40; //1-399
textStyle.Bold = false;
textStyle.Italic = false;
textStyle.Underline = false;
 
TabulationParagraph paragraph = new TabulationParagraph(paragraphStyle);
paragraph.AddPortion("Some text", textStyle);
 
Tabulation_addParagraph(paragraph);
</source>

Revision as of 09:28, 18 July 2018

TabulationBulletNumeric



Settings for Numericbullets on paragraph

Constructors

  • () - Create a new BulletSetting for a Numeric list

Methods

  • string ToString() - The string representation of the object.

Properties

  • Color Color { get; set; } - Get/Set Color of bullets and numbers
  • bool IsPrefixed { get; set; } - Get/Set if the number is prefixed with parent numbers.
  • int Level { get; set; } - Get/Set Level of nesting of list element
  • string ObjectTypeName { get; } - The name of the type of object.
  • int StartNumber { get; set; } - Get/Set startnumber for this sequence - set to -1 for not set
  • TypeInformation TypeInformation { get; } - Get information about this class.


Examples

TabulationBulletNumeric bulletNum = new TabulationBulletNumeric();
//For all bullet types
bulletNum.Level = 1;//Defines what level of the list we want the paragraph. 
bulletNum.Color = Color_getByName("green");
bulletNum.StartNumber = 1;//The number the list should start with. Must only be set for the first element. 
bulletNum.IsPrefixed = false; //Indicates if the list in the pdf shoud prefix the number with higher levels ie: true: 1.1.2. false: 2.

TabulationParagraphStyle paragraphStyle = new TabulationParagraphStyle();
paragraphStyle.SetBulletSetting(bulletNum);
paragraphStyle.Alignment = "center"; //left, right, center.
paragraphStyle.MarginTopPoints = 10; //0-400
paragraphStyle.MarginLeftPoints = 10;//0-400

TabulationTextStyle textStyle = new TabulationTextStyle();
textStyle.Color = Color_getByName("red"); //Takes a color array-
//textStyle.Color = Color_getByRGB(255,0,0); // can also be set from rgb.
//textStyle.Color = new Color("red",false); // can also be set by Color object
textStyle.FontFace = "Bariol Regular";
textStyle.FontSize = 40; //1-399
textStyle.Bold = false;
textStyle.Italic = false;
textStyle.Underline = false;

TabulationParagraph paragraph = new TabulationParagraph(paragraphStyle);
paragraph.AddPortion("Some text", textStyle);

Tabulation_addParagraph(paragraph);