From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Xah Lee Newsgroups: gmane.emacs.help Subject: Re: replace placeholders Date: Tue, 3 Mar 2009 12:36:46 -0800 (PST) Organization: http://groups.google.com Message-ID: <739d03fc-5be5-48f5-9a36-30603e38110f@v5g2000prm.googlegroups.com> References: <873adxogmg.fsf@literaturlatenight.de> <87wsb8vx19.fsf@literaturlatenight.de> <877i36obde.fsf@literaturlatenight.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1236115811 19210 80.91.229.12 (3 Mar 2009 21:30:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 3 Mar 2009 21:30:11 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Mar 03 22:31:27 2009 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LecCT-0004qq-Km for geh-help-gnu-emacs@m.gmane.org; Tue, 03 Mar 2009 22:30:53 +0100 Original-Received: from localhost ([127.0.0.1]:43964 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LecB8-0005jJ-F8 for geh-help-gnu-emacs@m.gmane.org; Tue, 03 Mar 2009 16:29:30 -0500 Original-Path: news.stanford.edu!headwall.stanford.edu!news.glorb.com!news2.glorb.com!postnews.google.com!v5g2000prm.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help,comp.emacs Original-Lines: 89 Original-NNTP-Posting-Host: 24.6.175.142 Original-X-Trace: posting.google.com 1236112606 19431 127.0.0.1 (3 Mar 2009 20:36:46 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Tue, 3 Mar 2009 20:36:46 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: v5g2000prm.googlegroups.com; posting-host=24.6.175.142; posting-account=bRPKjQoAAACxZsR8_VPXCX27T2YcsyMA User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10_4_11; en) AppleWebKit/525.27.1 (KHTML, like Gecko) Version/3.2.1 Safari/525.27.1, gzip(gfe), gzip(gfe) Original-Xref: news.stanford.edu gnu.emacs.help:167262 comp.emacs:97911 X-Mailman-Approved-At: Tue, 03 Mar 2009 16:26:23 -0500 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:62563 Archived-At: On Mar 3, 7:49 am, henry atting wrote: > On Mo, M=C3=A4r 02 2009, Peter Dyballa wrote: > > > Am 02.03.2009 um 15:06 schrieb henry atting: > > >> I simply typed \226 to `query-replace's prompt. > > > It should have been: C-q 2 2 6 =E2=80=93 and so= metimes > > care needs to be taken: GNU Emacs 23.x (could be also 22.x) can be > > set to accept hex (to input directly Unicode characters) and other > > coding instead of octal. Now you have strings comprised of \, 2, and > > 6. > > Yes, this works fine. > Strange. After I eliminated all these placeholders (it is a *.tex file) > I do not really miss anything in the PDF output, the source does not > contain any letter with a circumflex. > Anyway, for now I do not have to convert any other latin1 file. the best way i found to replace is simply copy & paste the char in query-replace. To find out what that char is, you can do =E2=80=9CCtrl+u Ctrl+x =3D=E2=80= =9D. It'll give you the full unicode name, code number, and all sort of info. But you have to intsall the unicode file... See: Q: I have this character =CE=B1 on the screen. How to find out its unicode's hex value or name? You can find out a character's decimal, octal, or hex values by placing your cursor on the character, and type =E2=80=9CAlt+x what-cursor- position=E2=80=9D (Ctrl+x =3D). You can get more info if you place your cur= sor on the character, then press =E2=80=9CCtrl+u Ctrl+x =3D=E2=80=9D. However, if you want the complete unicode info of a character, you need to download a unicode data file and let emacs know where it is. The unicode data file can be downloaded at: http://www.unicode.org/Public/U= NIDATA/UnicodeData.txt. After you downloaded it, place the following code in your =E2=80=9C~/.emacs= =E2=80=9D to let emacs know where it is: ; set unicode data file location. (used by what-cursor-position) (let ((x "~/Documents/emacs/UnicodeData.txt")) (when (file-exists-p x) (setq describe-char-unicodedata-file x))) Then restart emacs. Once you've done this, then place your cursor on a unicode char, and do =E2=80=9CCtrl+u Ctrl+x =3D=E2=80=9D, then emacs will g= ive you all the unicode info about that char, including the code point in decimal, octal, hex notations, as well the unicode character name, category, the font emacs is using, and others. For example, here's the output on the character =E2=80=9C=CE=B1=E2=80=9D: character: =CE=B1 (332721, #o1211661, #x513b1, U+03B1) charset: mule-unicode-0100-24ff (Unicode characters of the range U+0100..U+24FF.) code point: #x27 #x31 syntax: w which means: word category: g:Greek buffer code: #x9C #xF4 #xA7 #xB1 file code: #xCE #xB1 (encoded by coding system mule-utf-8-unix) display: by this font (glyph code) -apple-symbol-medium-r-normal--14-140-72-72-m-140-mac-symbol (#x61) Unicode data: Name: GREEK SMALL LETTER ALPHA Category: lowercase letter Combining class: Spacing Bidi category: Left-to-Right Uppercase: =CE=91 Titlecase: =CE=91 There are text properties here: fontified t above from: =E2=80=A2 Emacs and Unicode Tips http://xahlee.org/emacs/emacs_n_unicode.html Xah =E2=88=91 http://xahlee.org/ =E2=98=84