Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

ps_set_text_pos(3) [php man page]

PS_SET_TEXT_POS(3)							 1							PS_SET_TEXT_POS(3)

ps_set_text_pos - Sets position for text output

SYNOPSIS
bool ps_set_text_pos (resource $psdoc, float $x, float $y) DESCRIPTION
Set the position for the next text output. You may alternatively set the x and y value separately by calling ps_set_value(3) and choosing textx respectively texty as the value name. If you want to output text at a certain position it is more convenient to use ps_show_xy(3) instead of setting the text position and call- ing ps_show(3). PARAMETERS
o $psdoc - Resource identifier of the postscript file as returned by ps_new(3). o $x - x-coordinate of the new text position. o $y - y-coordinate of the new text position. RETURN VALUES
Returns TRUE on success or FALSE on failure. EXAMPLES
Example #1 Placing text at a given position <?php $ps = ps_new(); if (!ps_open_file($ps, "text.ps")) { print "Cannot open PostScript file "; exit; } ps_set_info($ps, "Creator", "rectangle.php"); ps_set_info($ps, "Author", "Uwe Steinmann"); ps_set_info($ps, "Title", "Text placement example"); ps_begin_page($ps, 596, 842); $psfont = ps_findfont($ps, "Helvetica", "", 0); ps_setfont($ps, $psfont, 8.0); ps_show_xy($ps, "Some text at (100, 100)", 100, 100); ps_set_value($ps, "textx", 100); ps_set_value($ps, "texty", 120); ps_show($ps, "Some text at (100, 120)"); ps_end_page($ps); ps_delete($ps); ?> SEE ALSO
ps_set_value(3), ps_show(3). PHP Documentation Group PS_SET_TEXT_POS(3)

Check Out this Related Man Page

PS_LINETO(3)								 1							      PS_LINETO(3)

ps_lineto - Draws a line

SYNOPSIS
bool ps_lineto (resource $psdoc, float $x, float $y) DESCRIPTION
Adds a straight line from the current point to the given coordinates to the current path. Use ps_moveto(3) to set the starting point of the line. PARAMETERS
o $psdoc - Resource identifier of the postscript file as returned by ps_new(3). o $x - x-coordinate of the end point of the line. o $y - y-coordinate of the end point of the line. RETURN VALUES
Returns TRUE on success or FALSE on failure. EXAMPLES
Example #1 Drawing a rectangle <?php $ps = ps_new(); if (!ps_open_file($ps, "rectangle.ps")) { print "Cannot open PostScript file "; exit; } ps_set_info($ps, "Creator", "rectangle.php"); ps_set_info($ps, "Author", "Uwe Steinmann"); ps_set_info($ps, "Title", "Lineto example"); ps_begin_page($ps, 596, 842); ps_moveto($ps, 100, 100); ps_lineto($ps, 100, 200); ps_lineto($ps, 200, 200); ps_lineto($ps, 200, 100); ps_lineto($ps, 100, 100); ps_stroke($ps); ps_end_page($ps); ps_delete($ps); ?> SEE ALSO
ps_moveto(3). PHP Documentation Group PS_LINETO(3)
Man Page

14 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Lp Print commands

How do you forward page while printing a report in Unix? Example: I notice the print was misaligned on pages 100-120, How can I forward the printer to start printing at pages 100 and end at 120? (1 Reply)
Discussion started by: ddameron
1 Replies

2. Shell Programming and Scripting

Number to Text

Please help me find a formula to convert the following numbers to text, such as 25.00 would be 0002500 25.50 would be 0002550 25.55 would be 0002555 I was thinking of divison by 100 or using MOD function. (2 Replies)
Discussion started by: Mastermind
2 Replies

3. UNIX for Dummies Questions & Answers

locating the line and print the output

hi all, I would like to know , if a file contains say 100 lines, and if i want to locate the 54th line and print the output , how to do it?? for eg , if a file details.txt which contains say 100 entries like admin .................... rajes .................... test ..................... (7 Replies)
Discussion started by: vasikaran
7 Replies

4. UNIX for Dummies Questions & Answers

Lookup with a file

Hi All, i have a variable which has a value in it. RETAILER='JEWL' i have a text file. Name: file.txt file.txt ________ WLG 150 JEWL 60 CVS 240 FLN 120 WND 120 I am trying to write a korn script.the script, based on the value in the RETAILER will do a look up against the... (5 Replies)
Discussion started by: pavan_test
5 Replies

5. AIX

43p 120

I have acquired a 43p 120 (7248-120) and I have two questions: Can anyone remember what is the highest version of AIX which I can install (5.1 I believe) and Can anyone remember how to boot this from the CDROM (boot floppy?) (1 Reply)
Discussion started by: johnf
1 Replies

6. Shell Programming and Scripting

remove specific lines from flat file using perl

Hi, Here is wat im looking for.. i have a flat file which looks like this.. 00 * * * * .. .. * * text text text COL1 COL2 ----- ----- 1 a (12 Replies)
Discussion started by: meghana
12 Replies

7. Shell Programming and Scripting

cutting a section of a big file

Hi, I have a text file 10giga size. Opening the file with vi takes forever ... Im intersting only with the 100 first records. Is there way to copy those 100 lines to new file (with no need to open the file)? Thanks (6 Replies)
Discussion started by: yoavbe
6 Replies

8. Solaris

NIC problem

can anyone help me fix this? what command should I use to bring them back to "TRUE"? Interface Speed Duplex Autoneg --------- ----- ------ ------- ce0 100 Mbit/s FULL FALSE ce5 100 Mbit/s FULL ... (3 Replies)
Discussion started by: uuontario
3 Replies

9. Shell Programming and Scripting

Calculate average of each of position of contents in a huge file

My input: >AAA_100 10 20 50 60 10 100 15 10 >AAA_100 20 20 50 60 20 100 15 10 >AAA_100 10 20 50 60 40 100 15 10 >AAA_100 40 20 50 60 10 100 15 10 . . . My Output 20 20 50 60 20 100 15 10 If I have a long list of file. I want to calculate average of each position inside the contents... (7 Replies)
Discussion started by: patrick87
7 Replies

10. Shell Programming and Scripting

Awk- How to extract duplicate expressions

How to extract duplicate expressions ? CD of c4 input c3 100 120 TF03_X2 + AABDDAAABDDBCBACDBBC c4 100 120 TF03_X3 + AABCDAAABDDBCBACDBBC Script awk '{ for(i=1; i<=NF; i++) if($5 == "+" && $6 ~/CD/) {print index($6,... (11 Replies)
Discussion started by: bumblebee_2010
11 Replies

11. Shell Programming and Scripting

Reading and analysing data in a text file

Hi, I have below type of data in a text file in unix. Emp_Name Emp_Dept Raj 101 Amruta 100 Shilpa 100 Rohit 123 Amol 198 Rosh 101 Gaurav 198 Number of employees can be even more. Need a command or a... (2 Replies)
Discussion started by: rajneesh_kapoor
2 Replies

12. Shell Programming and Scripting

cutting long text by special char around 100 byte and newline

Regard, How can i cut the text by special char(|) around 100 byte and write the other of the text at newline using Perl. ... (3 Replies)
Discussion started by: Shawn, Lee
3 Replies

13. Shell Programming and Scripting

Help with Complex Awk.

Hi, I have a file. In this file when ever the word "ABC" occurs at position from 25 and 34 I would like to replace the value at postion 100 to 5 for the first 1000 rows only. I have written the following Awk command. nawk 'substr($0,25,9)=="ABC" {print $0}' filename The above command... (4 Replies)
Discussion started by: pinnacle
4 Replies

14. Shell Programming and Scripting

Gnuplot 3d binning

Hello I have a text file with tens of thousands of rows The format is x y where both x and y can be anything between -100 and +100. What I would like to do is have a 3d gnuplot where there are 10,000 squared or bins and each bin will count how many rows have a value that would be... (1 Reply)
Discussion started by: garethsays
1 Replies