Post Reply 
 
Thread Rating:
  • 288 Votes - 2.75 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Page 2: Displaying Text and Text Styles
06-16-2011, 01:17 PM (This post was last modified: 06-23-2011 03:48 PM by ashimo.)
Post: #1
Page 2: Displaying Text and Text Styles
Displaying Text in the Browser

1. Double-click “start.curl” in the Project pane.



2. The contents of the start.curl file appear in the editor. The first five lines of the file are declarations. The source code follows these statements.



3. Here, let’s write “Hello Curl!” Figure 1-12 shows where this appears in the program.



4. Click the “Save” button at the top left corner of the screen. The file is saved.


5. Click the “Run file” button. The program is executed. The browser will start and “Hello Curl!” will be displayed.


Setting Different Kinds of Text Styles

Next, we’ll use a style to display text for which we’ve specified a range of fonts.

1. To set a text style, we’ll use a format called text. By attaching different options to this style, we can set a color or a font. In the editor pane, add the following program code. Rather than input the following from scratch, you can use the editor to open the c:\Curl\Try\01_hello_curl\start.curl sample and then copy and paste.

Code:
{text
   font-style = italic,
   font-size = 30pt,
   color = red,
   Text with color or font setting
}
    
{bold {italic Text using defined format}}



2. Save and then execute the program. The text is displayed in the set style.

Find all posts by this user
Quote this message in a reply
01-13-2014, 04:01 PM
Post: #2
RE: Page 2: Displaying Text and Text Styles
Nice discussion .... Thanks

faris
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Page 6: Summary and Extra Practice ashimo 0 3,163 06-20-2011 05:11 PM
Last Post: ashimo
  Page 5: Examining the Program Structure of Images and Links ashimo 0 3,251 06-16-2011 01:50 PM
Last Post: ashimo
  Page 4: Images and Links ashimo 0 2,909 06-16-2011 01:41 PM
Last Post: ashimo
  Page 3: Examining the Program Structure of Text Display ashimo 0 3,253 06-16-2011 01:38 PM
Last Post: ashimo
  Page 1: Creating a Project ashimo 0 2,831 06-16-2011 01:14 PM
Last Post: ashimo
Forum Jump:


User(s) browsing this thread:
1 Guest(s)