Hi,
I have file as shown below.
abc,
def,
abc,
xyz,
I have to remove ',' from end of last line (xyz,). How can I do that with single command? Is it possible or I have to iterate through complete file to remove that?
- Malay (2 Replies)
I'm appending header and trailer record for a binary file using
echo "$header" > filename
cat oldfilename >> filename
echo "$trailer" >> filename
The echo is introducing newline character after header and trailer.Please let me know is there any possibility to get rid of newline character. (2 Replies)
HI i am having a file this
(sys19:pnlfct:/pfact/temp>) cat temp_sand
1234567890
1234567890
1234567890
1234567890
I want to make this file as
(sys19:pnlfct:/pfact/temp>) cat temp_sand
1456789023
1456789023
1456789023
1456789023
just take the 2nd and 3rd position and put it... (5 Replies)
How can I remove the last character from each line of a file?
This must be done without "funny" characters, as I want to transfer the code to/from Windows.
Any ideas? (17 Replies)
hi
Someone can give me some clue or script in writing the below requirement
I am having 5 or 10 files of unix files which contain ^M charactes.
First we have to find ^M character and concat the line where it has broken and then we have to remove the ^M character from the uxix... (11 Replies)
Hi Experts,
I have data coming in 4 columns and there are new line characters \n in between the data. I need to remove the new line characters in the middle of the row and keep the \n character at the end of the line.
File is comma (,) seperated.
Eg:
ID,Client ,SNo,Rank
37,Airtel \n... (8 Replies)
Hi there,
A total sed noob here. Is there a way using sed to delete everything before a character AND after another character on each line in a file? The deletion should also delete the indicating characters(here: an opening and a closing parenthesis).
The original file would look like... (3 Replies)
Hi friend,
I have one file , and i want to read that file character by character.
I need this script in ksh.
while using read option with -n1 am getting error.
while read -n1 c read has bad option
And if i am using below script, then if in a line has space like this ( Pallvi mahajan)... (10 Replies)
Hello guys,
I would need to remove the last character ")" of a specific line. This can be from any line. Your help is appreciated. Below is the line.
HOSTNAME=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP))
Please help. (6 Replies)
Discussion started by: sang8g
6 Replies
LEARN ABOUT DEBIAN
mdraw_coordinates_position
mdraw_coordinates_position(3m17n) The m17n Library mdraw_coordinates_position(3m17n)NAME
mdraw_coordinates_position - Return the character position nearest to the coordinates.
SYNOPSIS
int mdraw_coordinates_position (MFrame * frame, MText * mt, int from, int to, int x_offset, int y_offset, MDrawControl * control)
DESCRIPTION
Return the character position nearest to the coordinates. The mdraw_coordinates_position() function checks which character is to be drawn
at coordinate (x, y) when the text between from and to of M-text mt is drawn at the coordinate (0, 0) using the mdraw_text_with_control()
function with the drawing control object control. Here, the character position means the number of characters that precede the character
in question in mt, that is, the character position of the first character is 0.
frame is used only to get the default face information.
RETURN VALUE
If the glyph image of a character covers coordinate (x, y), mdraw_coordinates_position() returns the character position of that
character.
If y is less than the minimum Y-coordinate of the drawn area, it returns from.
If y is greater than the maximum Y-coordinate of the drawn area, it returns to.
If y fits in with the drawn area but x is less than the minimum X-coordinate, it returns the character position of the first character
drawn on the line y.
If y fits in with the drawn area but x is greater than the maximum X-coordinate, it returns the character position of the last
character drawn on the line y.
COPYRIGHT
Copyright (C) 2001 Information-technology Promotion Agency (IPA)
Copyright (C) 2001-2011 National Institute of Advanced Industrial Science and Technology (AIST)
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License
<http://www.gnu.org/licenses/fdl.html>.
Version 1.6.2 12 Jan 2011 mdraw_coordinates_position(3m17n)