LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-31-2013, 08:16 AM   #1
Futilis
LQ Newbie
 
Registered: Dec 2013
Distribution: rhel 5
Posts: 5

Rep: Reputation: Disabled
Emacs, install more coding systems


Hi,

I am using emacs in hexl-mode to edit binary print files wich have ebcdic text in them.

Emacs (21) does not seem to have an ebcdic coding system, and this makes the above rather cumbersome.

My question is
How can I write and install an ebcdic coding system in Emacs 21.4 ?


I viewed files like
/usr/share/emacs/21.4/lisp/international/latin-1.el
hoping that I could write my own ebcdic coding in one of them, but these seem to have code points over 160 only (lines like
(set-case-syntax-pair 166 182 tbl) ;latin letter h with circumflex) )

It needs to be emacs 21.4, so that I can use it at work.

Thanks for any tips.
Joram
 
Old 01-01-2014, 01:16 AM   #2
Z038
Member
 
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 910

Rep: Reputation: 174Reputation: 174
I don't use Emacs, so I can't answer your questions. I often use okteta (a simple KDE hex editor) to edit EBCDIC text files.
 
Old 01-02-2014, 02:40 AM   #3
Futilis
LQ Newbie
 
Registered: Dec 2013
Distribution: rhel 5
Posts: 5

Original Poster
Rep: Reputation: Disabled
Hi,

Pure ebcdic text files do not pose much of a problem. I just convert them using dd before editing and convert them back after.
The point is that these are binary print files, containing ebcdic strings. So, I cannot convert all of the file before loading into emacs. I need to change the hexl-mode's representation.

Cheers
 
Old 01-02-2014, 11:06 AM   #4
Z038
Member
 
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 910

Rep: Reputation: 174Reputation: 174
Give okteta a try. It is a GUI raw file editor that displays the file in both hexadecimal and in text in separate parts of the window. It can display the text using any one of many different code pages that it supports, including EBCDIC. It just interprets the binary data in whatever code page you specify for the purpose of displaying it on the screen as an aid to editing, but it doesn't actually convert anything in the underlying raw file, so there is no risk of corruption to any of the data.

I think okteta is perfect for what you want to do.

I really don't know anything about Emacs, but I did find this info about an EBCDIC table on the Emacs wiki. Maybe it will be useful to you.

Last edited by Z038; 01-02-2014 at 11:32 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Enable color coding in Emacs? jnojr General 23 12-16-2010 02:29 PM
emacs and multiple files open in seperate windows from remote systems poundjd Linux - Newbie 3 03-27-2010 12:24 AM
install programs without coding help_a_newbie Linux - Distributions 3 07-15-2007 09:41 AM
Emacs module for better perl coding rose_bud4201 Linux - Software 3 04-27-2005 02:39 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration