Formatting text using Switches:


 

In Baraha, by default, the Language, Font, Text Size, Text Color, Alignment, Bold, Italic, Underline and other formatting attributes of the output text are determined by the default values, that are specified in the Default Settings dialog box. The default values affect the entire output text. It is possible to selectively format the output text by using the Tags inside the angle brackets (< >), which is called a Switch. A switch is nothing but a group of one or more tags. If more than one tag is specified in a switch, they have to be separated by either ' | ' or ' / ' character.

 

Example:

Switches containing a single tag.

<justify> <img=test.bmp height=40 width=40>

 

Switches containing two tags.

<font="Kai Baraha"|size=12> <img=test.bmp height=40 width=40|lang=kan>

 

Every formatting attribute has an associated tag. Attribute values specified using the tags override the default values. A tag affects the value of the corresponding attribute, for all the text that follows it, until it is overridden by the same tag with a different value, or turned OFF using the corresponding closing tag. When a tag is turned OFF, the default value will be used for that attribute from that point onwards.

 

For example, size=32 tag specifies the text size of 32 points. This size will be used for all the text that follows the switch. Later, if we use size=12 tag, the size of the following text becomes 12 points. When we turn OFF the size value using the closing tag -size, the default text size will be used from that point onwards. Tags are also used for inserting lines, graphics, hyperlinks.

 

Example:

<size=32>32pt, <size=12>12pt, <-size>Default Size.

32pt, 12pt, Default Size.

 

A tag is composed of one or more Parameters. A parameter can be just a Name or Name=Value pair. If more than one parameter has to be specified, a space(' ') or comma(',') is used to separate them. If the Value itself has a space or comma character, double quotes should be used to enclose the value.

 

Note:

Parameter can be just the Name type.

<newpage>

 

Parameter can be a Name=Value pair type.

<color=red>

 

More than one parameters in a tag should be separated by space or comma character.

<img="d:\temp\picture.bmp" width=100 height=100> <box bgcolor="green", border="1"|size=12>

 

If the Value has space or comma characters, double quotes should be used.

<font="Times New Roman">

 

Usage of tags with examples is explained in the following sections.

 

Tags:

 

Alignment
Box

Bullet Lists
Columns

Comment
Font

Hyperlink
Indentation

Label
Language

Latin Output
Line

Line Spacing
Page/Column Break

Picture
Tabstops

Text Background Color
Text Color

Text Scale
Text Size

Text Style

 


 

 

Alignment:

Use left, center, justify and right tags for aligning the text.

 

Example:

<center>kannaDake hOrADu kannaDada kaMda kannaDava kApADu nanna AnaMda jOguLada harakeyidu mareyadiru chinna mareteyAdare nInu maretaMte nanna

 

PÀ£ÀßqÀPÉ ºÉÆÃgÁqÀÄ PÀ£ÀßqÀzÀ PÀAzÀ

PÀ£ÀßqÀªÀ PÁ¥ÁqÀÄ £À£Àß D£ÀAzÀ

eÉÆÃUÀļÀzÀ ºÀgÀPɬÄzÀÄ ªÀÄgÉAiÀÄ¢gÀÄ a£Àß

ªÀÄgÉvÉAiÀiÁzÀgÉ ¤Ã£ÀÄ ªÀÄgÉvÀAvÉ £À£Àß

 

The closing tag -align turns OFF the alignment attribute, and the default alignment value will be used from that point onwards.

 


 

 

Box:

Use box tag to specify an enclosing box for the text. All the paragraphs that follows until the -box tag, will be drawn inside a box. The background color and the border thickness of the box can also be specified.

 

Parameters:

bgcolor:

Specifies the color of the box. The value can be either a named color (such as red, blue, green, yellow, magenta, cyan, black, white, gray) or a six character hexadecimal RGB (Red, Green and Blue) color code (such as #8ab7e0). By default, the background color is grey.

 

border:

Specifies the thickness of the borderline of the box. The value should be a number between 0 - 10. By default, the border thickness is 0.

 

Example:

<box bgcolor=green border=2> hasiru DabbadoLage akSharagaLu. <-box>

 

ºÀ¹gÀÄ qÀ§âzÉÆ¼ÀUÉ CPÀëgÀUÀ¼ÀÄ.

 

 

The closing tag -box turns OFF the box attribute.

 


 

 

Bullet Lists:

Use list tag to specify the bullet list style for the paragraphs. All the paragraphs that follow, until the -list tag will have the bullet style. The style of the bullets can be specified by style parameter.

 

Parameters:

style:

Specifies the style of the bullets. The various styles are specified using a number between 0 - 7. By default, the style is 0.

 

0:    Squares

1:    Circles

2:    Diamonds

3:    Arrows

4:    No.

5:    No)

6:    (No)

7:    [No]

 

Example:

<list style=4>kuveMpu kAraMta bEMdre <-list>

 

  1. PÀĪÉA¥ÀÅ

  2. PÁgÀAvÀ

  3. ¨ÉÃAzÉæ

 

The closing tag -list turns OFF the list attribute.

 


 

 

Columns:

The no. of columns is usually specified in the "Page Setup" dialog box. But, this value can be overridden by the column information specified in the document itself using the columns tag.

 

Parameters:

columns:

Specifies the no. of columns to be used for the document. The value should be between 1 - 8.

 

 

Example:

<columns=3>

 

There is no closing tag for the columns tag.

 


 

 

Comment:

The text written between /* and */ is called comment. Commented characters are not transliterated by Baraha and are printed in English on the Output Window "as they appear" in the Input Window.

 

When the document is exported as an HTML file, the commented text is copied "as is". So, java scripts, and other HTML code can be used in the Baraha document in the form of comments, which will be retained when exported as HTML document.

 


 

 

Font:

Use font tag to specify the font for the output text.

 

Parameters:

font:

Specifies the name (typeface) of the font. The specified font should be installed in the system.

 

English Fonts:

For English text you can use any English font that is installed in your system.

 

Example:

<lang=eng /font="Courier">Courier Font Style Text

Courier Font Style Text

 

Kannada Fonts:

The Kannada fonts supplied with Baraha 5.0 software comply with the Kannada font standard directed by the Karnataka Govt. In addition to these fonts, you may also use the fonts from other vendors, which comply with the standard. For using other third party fonts with Baraha, read the "Using Other Fonts" topic in the Baraha help.

 

The following are the Kannada fonts that ship with the Baraha.

 

Example:

<lang=kan|font="BRH Kannada">celuva kannaDa nADu

ZɮĪÀ PÀ£ÀßqÀ £ÁqÀÄ

<lang=kan|font="BRH Kailasam">celuva kannaDa nADu

ZɮĪÀ PÀ£ÀßqÀ £ÁqÀÄ

 

"BRH Kannada Extra" font consists of the same glyphs that are in the "BRH Kannada" font. The "BRH Kannada Extra" font has more vertical space between the characters in order to accommodate the vedic symbols- such as anudhAththa, swaritha, dhIrghaswaritha, laghu and guru symbols.

 

Devanagari Fonts:

The following are the Devanagari fonts that ship with the Baraha.

 

Example:

<lang=hin|font="BRH Devanagari">merA bhArat mahAn

qÉåUÉ pÉÉUiÉ qÉWûÉlÉ

<lang=hin|font="BRH Kalidasa">merA bhArath mahAn

qÉåUÉ pÉÉUiÉ qÉWûÉlÉ

 

"BRH Devanagari Extra" font consists of the same glyphs that are in the "BRH Devanagari" font. The "BRH Devanagari Extra" font has more vertical space between the characters in order to accommodate the vedic symbols- such as anudhAththa, swaritha, dhIrghaswaritha, laghu and guru symbols.

 

Tamil Fonts:

The following are the Tamil fonts that ship with the Baraha.

 

Example:

<lang=tam|font="BRH Tamil">tamizh mozhi iniyatu

¾Á¢ú ¦Á¡Æ¢ þÉ¢ÂÐ

 

Baraha follows TSCII 1.7 standard for Tamil fonts. For using other third party fonts with Baraha, read the "Using Other Fonts" topic in the Baraha help.

 

Telugu Fonts:

The following are the Telugu fonts that ship with the Baraha.

 

Example:

<lang=tel|font="BRH Telugu">telugu mATa tIpu

hÇvÀSµÀ ¶¢Ãd j¶pÁ

 

"BRH Telugu Extra" font consists of the same glyphs that are in the "BRH Telugu" font. The "BRH Telugu Extra" font has more vertical space between the characters in order to accommodate the vedic symbols- such as anudhAththa, swaritha, dhIrghaswaritha, laghu and guru symbols.

 

Malayalam Fonts:

The following are the Malayalam fonts that ship with the Baraha.

 

Example:

<lang=mal|font="BRH Malayalam">kEraLa rAjyaM manOharamAN

¥Kkn kxRõI i¥dxtkixY§

 

"BRH Malayalam Extra" font consists of the same glyphs that are in the "BRH Malayalam" font. The "BRH Malayalam Extra" font has more vertical space between the characters in order to accommodate the vedic symbols- such as anudhAththa, swaritha, dhIrghaswaritha, laghu and guru symbols.

 

Gujarati Fonts:

The following are the Gujarati fonts that ship with the Baraha.

 

Example:

<lang=guj|font="BRH Gujarati">ame bhAratIya ChIe

A®Ðê ¬ÐгúoÐկРTúÕAê

 

 

Gurumukhi Fonts:

The following are the Gurumukhi fonts that ship with the Baraha.

 

Example:

<lang=pun|font="BRH Gurumukhi">maiM ikk bhAratIy hAM

hª² £B±E g¢kX¤j q¢³

 

 

Bengali Fonts:

The following are the Bengali fonts that ship with the Baraha.

 

Example:

<lang=ben|font="BRH Bengali">Ami bhAratIY

Açèh g²ç³fY²é³i

 

 

Oriya Fonts:

The following are the Oriya fonts that ship with the Baraha.

 

Example:

<lang=ori|font="BRH Oriya">mu~M jaNe bhAratIY.

iøÊ SÑZ hÇlaÉk–.

 

The closing tag -font turns OFF the font attribute and the default font of the current language will be used from that point onwards.

 


 

 

Hyperlink:

Use link tag to link to external documents, URLs as hyperlinks.

 

Hyperlinks are used to connect two or more related documents for navigational purpose. In Baraha, hyperlinks can be used to navigate(jump) from one baraha document to another baraha document or other types of documents such as MS Word, HTML documents e.t.c. A hyperlink in Baraha is created by associating a target document with a word(s), which creates a "hot spot". When this "hot spot" is clicked, the target document will open either in Baraha or some other application depending on the type of the document.

 

Parameters:

link:

Specifies the URL(path) of the target document. The target document may be either on the local hard disk or on the Internet. The path can be an absolute or a relative one. Relative paths are resolved w.r.t the path of the currently opened document. If the first character of the link is '#', then the link refers to a label within the document.

 

target:

Specifies where the target document should be opened. If the value is same, the target document will be opened in the same Baraha program. If the value is new, the target document will be opened in a new window. When you use target=same parameter, make sure that the target document is a Baraha(.brh file) document type. By default, the target document will be opened in an external window.

 

Example:

The following examples show the usage of absolute & relative paths for the target document.

 

<link="http://baraha.com/chapter1.brh", target=new>chapter 1<-link> <link="..\docs\chapter1.brh", target=same>adhyAya 1<-link> <link="c:\baraha\docs\story.htm">ek kahAni<-link> <link="../pics/house.gif">merA ghar<-link> <link="..\docs\resume.doc">My resume<-link>


 

The following example shows linking to a label within the same document.

 

<link="#MyLabel">Click here to read Chapter 1.<-link>

Click here to read Chapter 1.

 

When the above link is clicked, the text marked by the label MyLabel will be located and shown at the top of the window.

 

The closing tag -link is used to mark the end of the hyperlink attribute of the text.

 

See also: Label

 


 

 

Indentation:

Use indent tag to specify the indentation for the text. All the paragraphs enclosed between the indent & -indent tags will have the indentation.

 

Parameters:

left:

Specifies the left indentation in inches.

 

right:

Specifies the right indentation in inches.

 

firstline:

Specifies the extra indentation for the first line of the paragraph in inches.

 

Example:

<lang=kan|indent left=1.0, right=1.0, firstline=0.5>shikShaNadalli mAdhyamada prashne mukhyavAdudu mattu mUlaBUtavAdudu. shaikShaNikavAgi svIkRutavAda vichAraveMdare tAynuDi athavA maguvina parisarada BASheyE shikShaNa mAdhyamakke sUkta. idE maguvina sahaja chiMtaneya, kalpaneya BAShe. yAvudE BAShe arthagrahikegAgi takkadAdudAgirabahudAdarU nAvu beLedubaMdiruva BAShe hAgU adara parisaravE namma chiMtane hAgU aBivyaktige hELi mADisiddu.

 

²PÀëtzÀ°è ªÀiÁzsÀåªÀÄzÀ ¥Àæ±Éß ªÀÄÄRåªÁzÀÄzÀÄ ªÀÄvÀÄÛ ªÀÄÆ®¨sÀÆvÀªÁzÀÄzÀÄ. ±ÉÊPÀëtÂPÀªÁV ¹éÃPÀÈvÀªÁzÀ «ZÁgÀªÉAzÀgÉ vÁAiÀÄÄßr CxÀªÁ ªÀÄUÀÄ«£À ¥Àj¸ÀgÀzÀ ¨sÁµÉAiÉÄà ²PÀët ªÀiÁzsÀåªÀÄPÉÌ ¸ÀÆPÀÛ. EzÉà ªÀÄUÀÄ«£À ¸ÀºÀd aAvÀ£ÉAiÀÄ, PÀ®à£ÉAiÀÄ ¨sÁµÉ. AiÀiÁªÀÅzÉà ¨sÁµÉ CxÀðUÀæ»PÉUÁV vÀPÀÌzÁzÀÄzÁVgÀ§ºÀÄzÁzÀgÀÆ £ÁªÀÅ ¨É¼ÉzÀħA¢gÀĪÀ ¨sÁµÉ ºÁUÀÆ CzÀgÀ ¥Àj¸ÀgÀªÉà £ÀªÀÄä aAvÀ£É ºÁUÀÆ C©üªÀåQÛUÉ ºÉý ªÀiÁr¹zÀÄÝ.

 

The closing tag -indent is used to mark the end of the indentation attribute of the text.

 


 

 

Label:

Use label tag to insert a label in the document. The labels are useful for linking between the different sections within the same document for navigational purposes. When a hyperlink pointing to a label is clicked, the label will be located and the document scrolls to the section marked by the label to show at the top of the window.

 

Parameters:

label:

Specifies the label. The value can be any text string.

 

Example:

<label="MyLabel">Chapter 1:

Chapter 1:

 

There is no closing tag for the label tag.

 

See also: Hyperlinks

 


 

 

Language:

Use lang tag to specify the language (Input Method).

 

Parameters:

lang:

Specifies the language (Input Method). Following values are allowed.

 

kan    => Kannada transliteration.

san    => Sanskrit transliteration.

hin    => Hindi transliteration.

mar    => Marathi transliteration.

tam    => Tamil transliteration.

tel    => Telugu transliteration.

mal    => Malayalam transliteration.

guj    => Gujarati transliteration.

pun    => Punjabi transliteration.

ben    => Bengali transliteration.

ori    => Oriya transliteration.

eng    => English.

 

Note: The transliteration rules for Hindi and Marathi languages are the same.

 

Example:

<lang=kan>bI<lang=eng>chi <lang=kan>yavara tiMmana tale

©Ãchi AiÀĪÀgÀ wAªÀÄ£À vÀ¯É

 

<lang=san>bhAShAsu mukhyA madhurA divyA gIrvANabhArati |

pÉÉwÉÉxÉÑ qÉÑZrÉÉ qÉkÉÑUÉ ÌSurÉÉ aÉÏuÉÉïhÉpÉÉUÌiÉ |

 

<lang=eng>I Love My<lang=hin> iMDiyA

I Love My CÇÌQûrÉÉ

 

<lang=tam>tamizh mozhi iniyatu

¾Á¢ú ¦Á¡Æ¢ þÉ¢ÂÐ

 

<lang=tel>eMdarO mahAnubhAvulu... aMdariki vaMdanamu...

IAlµ±Ð ¶¢À¶®¶mÀsû¹¶¢ÁvÀ... CAlµ±¼Oº ¶¢Alµ¶m¶¢ÀÀ...

 

<lang=mal>kEraLa rAjyaM manOharamAN

¥Kkn kxRõI i¥dxtkixY§

 

<lang=guj>amAro desh bhArat Che

A®ÐгúÐê sêú»Ð ¬ÐгúoÐ Têú

 

<lang=pun>bhArat mADA desh hai

g¢kX h¢T¢ Z©p qª

 

<lang=ben>bhArat AmAr desh

g²ç³fY² Açhç³f ôam

 

<lang=ori>mor janmabhoomi bhaarat

ÑiÇl SeðhÌiÈ hÇla

 

 

The closing tag -lang turns OFF the language attribute and the default language will be used from that point onwards.

 


 

 

Latin Output:

Use latin tag to display Indic scripts using Latin characters.

 

Example:

<lang=guj|latin>vaiShNava janato tene kahiye je pIDa parAyI jANere<-latin>

vai½³ava janatµ t£n£ kahiy£ j£ p§¢a par¡y§ j¡³£r£

 

The closing tag -latin turns OFF the latin attribute and the respective scripts are used from that point onwards.

 


 

 

Line:

Use line tag to insert a horizontal line. Line length, thickness, color, and style can be specified using the parameters.

 

Parameters:

width:

Specifies the thickness of the line in pixels. The value should be a number between 0 - 10.

 

length:

Specifies the length of the line in inches. If the length is not specified, the line will be drawn for the entire width of the page.

 

color:

Specifies the color of the line. The value can be either a named color (such as red, blue, green, yellow, magenta, cyan, black, white, gray) or a six-character hexadecimal RGB (Red, Green and Blue) color code (such as #8ab7e0).

 

style:

Specifies the style of the line. The values can be solid, dash, dot, and dashdot. Only solid styled lines can have thickness > 1.

 

Example:

<line style=solid length=2.0 width=5>


 

 

<line style=dot>


 

 

There is no closing tag for the line tag.

 


 

 

Line Spacing:

Use ls tag to specify the spacing between the lines.

 

Parameters:

ls:

Specifies line spacing. The value should be a number between 0.5 - 4.0. Value 1 represents single line spacing.

 

Example:

<ls=0.8>kaDime aMtarada sAlugaLu

PÀrªÉÄ CAvÀgÀzÀ ¸Á®ÄUÀ¼ÀÄ

PÀrªÉÄ CAvÀgÀzÀ ¸Á®ÄUÀ¼ÀÄ

 

<ls=1.4>heccu aMtarada sAlugaLu

ºÉZÀÄÑ CAvÀgÀzÀ ¸Á®ÄUÀ¼ÀÄ

ºÉZÀÄÑ CAvÀgÀzÀ ¸Á®ÄUÀ¼ÀÄ

 

The closing tag -ls turns OFF the line spacing attribute and the default line spacing will be used from that point onwards.

 


 

 

Page/Column Break:

Use newpage, newcolumn tags to specify a hard page break or column break.

 

Page (column) break is the point at which one page (column) ends and another begins when the document is printed or exported as picture files. When a page (column) is filled with text, Baraha "automatically" starts on a new page (column), which is called soft page (column) break. To force a page (column) break at a specific location, you can insert a newpage (newcolumn) tag. This is called hard page (column) break. In the print preview, in a printed document, and when exported as picture files, the text after a hard page (column) break appears on a new page (column).

 

Example:

<newpage> <newcolumn>

 

There is no closing tag for the newpage, newcolumn tags.

 


 

 

Picture:

Use img tag to insert a picture in the document. BMP, GIF, and JPG file formats are supported.

 

Parameters:

img:

Specifies path of the picture file. This path can be an absolute or a relative one.

 

width:

Specifies output width of the picture file in pixels. If this value is not specified, the actual width of the picture will be used.

 

height:

Specifies output height of the picture file in pixels. If this value is not specified, the actual height of the picture will be used.

 

trans:

Specifies transparent color. The value can be either a named color (such as red, blue, green, yellow, magenta, cyan, black, white, gray) or a six-character hexadecimal RGB (Red, Green and Blue) color code (such as #8ab7e0). If the transparent color is specified with the img tag, that color will be made transparent when the picture is drawn. If this parameter is not specified, the picture will be drawn opaque. Only the pictures with 256 or less colors can be made transparent.

 

Example:

<img="d:\pics\karnataka.bmp">

 

 

<img="d:\pics\karnataka.bmp" width=70 height=100>

 

 

<img="d:\pics\karnataka.bmp" width=70 height=100 trans=green>

 

 

There is no closing tag for the img tag.

 


 

 

Tabstops:

By default, Baraha uses some arbitrary tabstops. Use tabs tag to specify the tab stops of required sizes. For tabs to work properly, left alignment should be used.

 

Parameters:

tabs:

Specifies comma separated tab stops in inches. The value should be enclosed in double quotes("").

 

Example:

<tabs="0.75,1.25,1.0"> <b>    shikhara    rAShTra    ettara<-b> 1.    everesT    nEpALa    8854 2.    ke-2    BArata    8616 3.    kAMcanajuMga    BArata    8585

 

    ²RgÀ    gÁµÀÖç    JvÀÛgÀ

1.    JªÉgɸïÖ    £ÉÃ¥Á¼À    8854

2.    PÉ-2    ¨sÁgÀvÀ    8616

3.    PÁAZÀ£ÀdÄAUÀ    ¨sÁgÀvÀ    8585

 

The closing tag -tabs turns OFF the tabstops attribute and the default tabstops value will be used from that point onwards.

 


 

 

Text Background Color:

Use bkcolor tag to specify the background color of the text.

 

Parameters:

bkcolor:

Specifies text background color. The value can be either a named color (such as red, blue, green, yellow, magenta, cyan, black, white, gray) or a six-character hexadecimal RGB (Red, Green and Blue) color code (such as #8ab7e0).

 

Example:

<lang=kan|bkcolor=#ffff00>haLadi baNNada hinnale

ºÀ¼À¢ §tÚzÀ »£À߯É

 

The closing tag -bkcolor to turns OFF the text background color attribute, and the default text background color (which is white) will be used from that point onwards.

 


 

 

Text Color:

Use color tag to specify the color of the text.

 

Parameters:

color:

Specifies text color. The value can be either a named color (such as red, blue, green, yellow, magenta, cyan, black, white, gray) or a six-character hexadecimal RGB (Red, Green and Blue) color code (such as #8ab7e0).

 

Example:

<lang=kan|color=blue>nIli baNNa

¤Ã° §tÚ

 

The closing tag -color turns OFF the text color attribute, and the default text color will be used from that point onwards.

 


 

 

Text Scale:

Use scale tag to specify the scale of the text. Scale refers to the width to height ratio of the text.

 

Parameters:

scale:

Specifies scale in percentage(%). A value of 100 indicates normal text. If the value is > 100, the text becomes wider. If the value is < 100, the text becomes narrower. The valid range for the value is 10-500.

 

Example:

<scale=150>Wider Text<scale=75> Narrow Text<-scale> Normal Text

Wider Text Narrow Text Normal Text

 

The closing tag -scale turns OFF the scale attribute, and the default scale (which is 100) will be used from that point onwards.

 


 

 

Text Size:

Use size switch to specify the text size(height).

 

Parameters:

size:

Specifies text size in points. The valid range for the value is 4 - 164 points.

 

Example:

<lang=kan|size=14>saNNa akSharagaLu

¸ÀtÚ CPÀëgÀUÀ¼ÀÄ

 

<lang=kan|size=28>doDDa akSharagaLu

zÉÆqÀØ CPÀëgÀUÀ¼ÀÄ

 

The closing tag -size turns OFF the text size attribute and the default text size will be used from that point onwards.

 


 

 

Text Style:

Use b, i, u, sub, and sup to turn ON the bold, italic, underline, subscript, and superscript attributes respectively.

 

Example:

<lang=eng|b>Bold <-b|i>Italic <-i|u>Underlined<-u> text

Bold Italic Underlined text

 

<lang=eng>2H<sub>2<-sub> + O<sub>2<-sub> = 2H<sub>2<-sub>O

2H2 + O2 = 2H2O

 

<lang=eng>E=MC<sup>2<-sup>

E=MC2

 

Use -b, -i, -u, -sub, and -sup to turn OFF the bold, italic, underline, subscript, and superscript attributes respectively.