gnu.jemacs.buffer

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Scripting » Kawa » gnu.jemacs.buffer 
gnu.jemacs.buffer
JEmacs and the gnu.jemacs.buffer Package

Provides various building blocks for building an Emacs-like text editor. It also provides a number of Scheme procedures that have the same name and similar functionality as the Emacs Lisp functions. Somewhat out of date. Check the JEmacs home page for more information.

It uses the Swing tool-kit.

Plan

The plan is to use this together with the (unfinished) gnu.jemacs.lang package to provide a fully-functional re-implementation of Emacs Lisp which compiles to Java bytecodes. I'm hoping volunteers will help me make "JEmacs" into something useful. I have fairly clear ideas about much of what need to be done. Contact me if you are interested.

Home page

There is now a JEmacs home page. Also check out the Kawa home page.

Screen snapshot

There is a now a teaser screen snapshot.

Status

Very unfinished proof of concerpt. It is a functional but very minimal editor. Many of the core Emacs concepts (keymaps, windows, frames, buffers, markers) are implemented, and generally in such a way as to provide the standard Emacs semantics. There are Scheme functions with the same name and similar behavior as the standard Emacs Lisp functions. However, there is only a very limited set of core "editing" commands, and no searching commands. And it is not robust or reliable.

To-do

A couple of things volunteers might start with (but let me know before you spend serious time on any of these):
  • Implement more of the editing commands: Insert/delete/forward/backward word/line.
  • Display the modeline in inverse video, but extend it to the full window width.
  • Come up with a design for narrowing a buffer. One possibility is to use some kind of invisible style for the text outside the narrowing. But I think a more flexible design would use an "IndirectDocument" class that refers to a sub-range of a buffer. This would help with "Indirect Buffers", and might be flexible and elegant in general.
  • Perhaps Buffer should inherit from Document (or rather DefaultStyledDocument). However, that might lose some flexibility.
  • Needs methods to control Window scrolling.
  • Think about how to map extents and faces to Swing attributes and styles.
  • Decide how to implement Emacs strings. Initially, we'll use kawa.lang.FString, but we do want to support strings with extents and text properties.

Usage

These classes depend on Swing, so make sure you have Swing available. Then make sure you have a version of the Kawa classes that contains the gnu.jemacs.buffer classes. (In other words, Kawa needs to have been configure --with-swing support.) Then just start Kawa in the usual way:
java kawa.repl
Then evaluate:
(emacs)
That brings up a Emacs window.

You can do (split-window) to create new (sub-)windows in an existing frame; type (make-frame) to create a new frame (to-level window), or do (get-buffer-create NAME) to create a new buffer. Note also how ctrl/B and ctrl/F have been bound to the correct functions. For other working key-bindings, look for the calls to define-key in emacs.scm.

The call (scheme-swing-window) creates a new Scheme interaction window.

License

Same as the package gnu.expr: Modified Gnu Public License. See the file COPYING. For now, the copyright holder is Per Bothner; in the future it may make more sense to make the FSF the copyright owner, since the plan is to use a lot of the existing ELisp packages once ELisp support is complete.

Author

Per Bothner, <bothner@gnu.org>
Java Source File NameTypeComment
Buffer.javaClass
BufferLocal.javaClass A buffer-local variable (Location).
BufferReader.javaClass
BufferWriter.javaClass A Writer that writes at a Buffer's point or a Marker.
CancelledException.javaClass Used to signal that an action was cancelled.
Command.javaClass
EFrame.javaClass
EKeymap.javaClass
EMenu.javaInterface
EToolkit.javaClass
EWindow.javaClass
InfProcessMode.javaClass Inferior process (external command) mode.
InputStreamHandler.javaClass Insert input from an InputStream into a buffer. This is typically output from an inferior process.
Marker.javaClass
Mode.javaClass Represents a "mode instance" - a mode active for a specific Buffer .
ProcessMode.javaClass
ReplMode.javaClass
SelfInsertCommand.javaClass
Signal.javaClass
TelnetMode.javaClass
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.