Run Jedit
Submitted by
LeGerfo on
Friday, 31 October, 2008 - 17:49
Hello,
I would like to launch JEDIT in a frame. Is it possible to use JEDIT Je = new JEDIT(); ???
or how can I do for this ? please help me ? Is there anybody ???
Greg
Create a new windows that receive external information
Submitted by
LeGerfo on
Thursday, 30 October, 2008 - 12:13
Hello,
I would like to join all JEDIT to my program.
I would like to add a special window which receive information from my class, in fact I need this:
1/ My Program lauch JEDIT
2/ I write in JEDIT in a normal text window (code)
3/ I read this code from JEDIT (even I don't save file)
4/ I send information in text to JEDIT in a special window
For each case (1,2,3,4) in which class I need to modify for realize that I want ?
Thanks
Greg
cannot start jEdit in Eclipse
Submitted by
jtestori on
Tuesday, 30 September, 2008 - 08:28
hi!
i'm trying to compile and run jEdit 4.3pre15 with Eclipse 3.3. i've tried with java 1.5 and 1.6. i always get the following exception:
10:26:41 [main] [warning] IOUtilities: Error moving file: java.io.FileNotFoundException: C:\Dokumente und Einstellungen\tej\.jedit\activity.log (Das System kann die angegebene Datei nicht finden) : C:\Dokumente und Einstellungen\tej\.jedit\activity.log (Das System kann die angegebene Datei nicht finden)
10:26:41 [main] [warning] jEdit: jedit.jar not in class path!
10:26:41 [main] [warning] jEdit: Assuming jEdit is installed in C:\ta33\Workspaces\VAEB\ZZZ_JEDIT.
10:26:41 [main] [warning] jEdit: Override with jedit.home system property.
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: java.lang.NoClassDefFoundError: A class required by class: org.gjt.sp.jedit.gui.statusbar could not be loaded:
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: java.lang.NoClassDefFoundError: org/gjt/sp/jedit/gui/statusbar (wrong name: org/gjt/sp/jedit/gui/StatusBar)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.BshClassManager.noClassDefFound(BshClassManager.java:567)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.BshClassManager.plainClassForName(BshClassManager.java:244)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.classpath.BshClassLoader.findClass(BshClassLoader.java:177)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.classpath.BshClassLoader.loadClass(BshClassLoader.java:110)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.lang.ClassLoader.loadClass(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.classpath.ClassManagerImpl.classForName(ClassManagerImpl.java:195)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.NameSpace.classForName(NameSpace.java:1318)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.NameSpace.getClassImpl(NameSpace.java:1218)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.NameSpace.getClass(NameSpace.java:1159)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.Name.consumeNextObjectField(Name.java:298)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.Name.toObject(Name.java:199)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.BSHAmbiguousName.toObject(BSHAmbiguousName.java:60)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.BSHAllocationExpression.objectAllocation(BSHAllocationExpression.java:86)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.BSHAllocationExpression.eval(BSHAllocationExpression.java:62)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:102)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:47)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.Interpreter.eval(Interpreter.java:644)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.Interpreter.eval(Interpreter.java:738)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.bsh.Interpreter.eval(Interpreter.java:727)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.BeanShellFacade._eval(BeanShellFacade.java:148)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.BeanShellFacade.eval(BeanShellFacade.java:113)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.BeanShell.eval(BeanShell.java:387)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.ServiceManager$Descriptor.getInstance(ServiceManager.java:297)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.ServiceManager.getService(ServiceManager.java:238)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.gui.StatusBar._getWidget(StatusBar.java:444)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.gui.StatusBar.(StatusBar.java:86)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.View.(View.java:1230)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.jEdit.newView(jEdit.java:2257)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.jEdit.newView(jEdit.java:2235)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.jEdit.newView(jEdit.java:2211)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at org.gjt.sp.jedit.jEdit$6.run(jEdit.java:3654)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.event.InvocationEvent.dispatch(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.EventQueue.dispatchEvent(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
10:26:41 [AWT-EventQueue-0] [error] BeanShellFacade: at java.awt.EventDispatchThread.run(Unknown Source)
regards, hannes
processKeyEvent method in KeyEventWorkaround class
Submitted by
funa_take on
Friday, 18 July, 2008 - 14:18
I have some questions for processKeyEvent method in KeyEventWorkaround class.
Q1
case KeyEvent.KEY_PRESSED:
....
default:
if (!evt.isMetaDown()) {
if (evt.isControlDown() && evt.isAltDown()) {
lastKeyTime = 0L;
}
.....
Why lastKeytime = 0 ,when Ctrl and Alt are downed.
Q2
case KeyEvent.KEY_TYPED:
....
if(((modifiers & InputEvent.CTRL_MASK) != 0
^ (modifiers & InputEvent.ALT_MASK) != 0)
|| (modifiers & InputEvent.META_MASK) != 0)
{
return null;
}
Why is it "xor" instead of "or"?
Whren I press Alt and Ctrl and "p key" on Keybord Tester, "CA+p p" is shown in TextField on Linux.
To solve this problem, the following code was compiled.
case KeyEvent.KEY_PRESSED:
....
default:
if (!evt.isMetaDown()) {
if (evt.isControlDown() && evt.isAltDown()) {
//lastKeyTime = 0L;
}
.....
case KeyEvent.KEY_TYPED:
....
if(((modifiers & InputEvent.CTRL_MASK) != 0
|| (modifiers & InputEvent.ALT_MASK) != 0)
|| (modifiers & InputEvent.META_MASK) != 0)
{
return null;
}
Does this code have the problem?
Component or piece of code for search and replace text multiline with java
Submitted by
andremonio on
Wednesday, 16 July, 2008 - 18:29
Hi everybody.
Do you have any component or piece of code for search and replace text multiline with java?
I have installed the jEdit and their sources, but it is huge and complex, and I only need this functionality to replace many of the type TXT files.
Thanks!
Best regards.
---- André Campanini - Brazil
jEdit Coding Standards
Hello,
I am a masters student at Penn State University and I am working on my masters thesis. My thesis discusses how complexity can proliferate through a software system as it evolves. Part of my thesis involves a case study of the jEdit program. I was wondering if any of the developers could let me know if jEdit complies to any particular style guidelines or coding standards and, if so, what those guidelines are. This would be extremely useful in my research. Any information you could give me would be very much appreciated. Thanks for this great product!!
Thanks!!
Understand Jedit coding
Submitted by
insp on
Monday, 24 March, 2008 - 05:49
Hi can any one help me to understand jedit coding. especially the view part of it.
I urgently need an editor in java with syntax highlighting.
can any one help me to separate the syntax highlighting feature of jedit and apply to a stand alone editor.
Its very urgent.. pls help
compile jEdit with JDK only?
Submitted by
khcon on
Thursday, 7 February, 2008 - 23:28
is there a way to compile jEdit using just the JDK 1.4.1 and no additional software like Ant? I can't install anything new onto that machine and the JDK is the only thing available. I also HAVE to compile it from source code ...
Thanks,
KH
display line numbers in gutter
Submitted by
xlinuks on
Saturday, 17 November, 2007 - 13:41
Hi!
I'm trying to set (programmatically) jEdit to display the line numbers at startup (These only appear if one presses Ctrl+E+T, jEdit doesn't seem to remember whether showing line numbers was turned on or off last time).
I think I have to tinker with the class Gutter.java from package org.gjt.sp.jedit.textarea
The method Gutter.setExpanded( true ); (I've put it in different locations) doesn't seem to work.
Does anybody have any idea what I'm doing wrong?
sql 2 html
Submitted by
mbisping on
Saturday, 17 November, 2007 - 11:25
Hello,
I'd like to present SQL from a database with syntax highlighting on a HTML-web page.
I thougt about combining the JEdit syntax package
with the Code2Html plugin.
However, even the old version of the plugin doesn't streamline with the jedit syntax code.
What would be the best/easiest way to create a java method like
/**
* param String sql - a number of sql statements
* returns syntax highlighted sql codes in HTML notation
**/
public String toSyntaxHighlightHTML(String sql)
Cheers
Meikel
Macro problem on self-built jEdit
Submitted by
jedi on
Thursday, 25 October, 2007 - 20:46
I checked out the HEAD from svn (rev 10955) and it compiled without errors. However, when I'm running it (ant run) it gives me errors from some of the built-in macros. For example:
Sourced file: /Users/jedi/projects/jedit/jEdit/build/macros/Editing/Emacs_Next_Line.bsh : Command not found: setAccessibility( boolean ) : at Line: 16 : in file: /Users/jedi/projects/jedit/jEdit/build/macros/Editing/Emacs_Next_Line.bsh : setAccessibility ( true )
Emacs_Next_Line works fine if I use it in the latest release (4.3pre1).
Has something been changed in the beanshell & macros since the latest release and how do I fix this?
Thanks!
autoindent and matlab
Submitted by
skvalen on
Monday, 3 September, 2007 - 14:29
hi, I have fiddled with the autoindent in matlab mode, and i come up with this:
< PROPERTY NAME="indentNextLines" VALUE="^\s*(if|for|function|switch|try|while)([\t ]*\(|[\t ]+|$).*(?!end)$" />
< PROPERTY NAME="indentNextLine" VALUE=".*?\.{3}.*" />
< PROPERTY NAME="unindentThisLine" VALUE="^\s*(end|else|elseif([\t ]*\(|[\t ]+).*|case|otherwise|catch)[\t ]*(%.*)?$" />
< PROPERTY NAME="unindentNextLines" VALUE="^\s*end\s*(%.*)?$" />
that gives something like this:
if foo
bar
end
foobar
and that is wrong, but if I mark it and press 'indent-lines' (c+i) I get:
if foo
bar
end
foobar
which is correct.
Anny idea who this can be correct on the fly?
mcse exam preps ?
Submitted by
jakannan on
Saturday, 25 August, 2007 - 22:01
i am studying for my mcse 2003 exams . I have a week to prepare for my 070-290 exam . Iam looking at
some practice exams to purchase for my exam . anyone knows how good are certmagic.com practice exam for
070-290 ? . plz let me know if they are well worth it or they are not
Developing jEdit in NetBeans
Dear jEdit developers,
I would like to let you now that we have recently ported jEdit 4.2 environment into the NetBeans IDE.
You may wish to check it out:
http://wiki.netbeans.org/wiki/view/NetbeansedJEdit
Now you can completely run, debug, and profile jEdit inside the NetBeans IDE, and have access to all nifty features NetBeans IDE provides to make developer's more productive and happy.
I would greatly appreciate any feedback you may have about my project and any ideas on how to make it more useful for jEdit community.
If you are new to NetBeans please go to http://www.netbeans.org for all information, tutorials and fun stuff.
Daria Titova
NetBeans Engineer.
Using addError & addExtraMessage - the ErrorList plugin API
I have been using jEdit alongside the Microsoft Visual C++ IDE (MSDEV) application for quite some time now, whilst writing embedded apps simulations PCs hosting XP.
Some time ago I bolted together a support tool that detected compilation log creation (.plg files generated by MSVC when compiling C/C++ projects) and then opened and parsed the errors & warnings.
From this data a bsh script file is generated, an then executed by jEdit to populate the ErrorList plugin's window accordingly.
So I can compile within another IDE, but edit and correct code within jEdit. Quite handy.
I later extended this tool to collate PC-Lint analysis results (also invoked within the IDE) in the same manner.
A typical example of the bsh file generated by the tool is as follows (I have only included a single addError invocation, but this is enough to demonstrate the script format):
//-----------------------------------------------------
import org.gjt.sp.jedit.*;
import org.gjt.sp.util.*;
import org.gjt.sp.jedit.gui.OptionsDialog;
import org.gjt.sp.jedit.msg.*;
import java.io.*;
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
import errorlist.*;
import java.util.*;
import gnu.regexp.*;
import console.*;
void run()
{
void log_errors()
{
errorlist.DefaultErrorSource errsrc;
errsrc = new errorlist.DefaultErrorSource("MSVC");
errorlist.ErrorSource.registerErrorSource(errsrc);
jEdit.getAction("error-list-clear").invoke(null);
errsrc.addError(ErrorSource.ERROR, "C:\\my_projects\\hw_if\\control\\ctrlapi.c",944,0,0,"LNT787: (Info -- enum constant 'DTV_PL_ASIG_AV_IP1_AUDIO' not used within switch)");
errsrc = null;
}
if(jEdit.getLastView() == null)
VFSManager.runInAWTThread(this);
else
log_errors();
}
run();
//-----------------------------------------------------
The problem I have here is that I wish to extend some of the messages in the plugin output to be multi-line, but I cannot see how to use the addExtraMessage method with the preceding code - can anybody explain how I would modify my bsh script output to permit this?
PS - if anyone else out there running a Windows OS also wants to generate errors/warnings in jEdit from externally generated files, then let me know!
changelog?
Submitted by
thefayth on
Wednesday, 18 April, 2007 - 08:50
hi,
i don't know what forum i should ask this in so i'll put it in here, sorry if it shoulsn't be, i was wondering does anyone know when i can access the changelog for jEdit i'm doing a little bit of research for a project and it would help if i had a changelog to see how its developed over time. Thanks for any help.
Syntax pakage, Undo and Redo and JavaCCLexer
Submitted by
kagepower on
Saturday, 31 March, 2007 - 18:34
Hello, I am from spain. I am developing an application, is a editor for javaCC.
But when using Syntax package in my project, undo and redo, it doesn't responded well.
I would like to know as making JavaCCLexer for to recognize reserved words.
help me plese... thank my mail is ronytour@hotmail.com
line numbers
Submitted by
mich24 on
Thursday, 14 December, 2006 - 09:26
Can somebody tell me in what class the line numbers of the program editor are displayed? I have to have a look on the code beacause I have to implement line numers in another editor...
thx a lot!
compilation errors
Submitted by
mich24 on
Thursday, 14 December, 2006 - 09:25
I have create a project with JBuilder with all the jEdit source files but I get many compilation errors... why?
Thx a lot for any ideas!
Trouble writing an edit mode with line continuation characters
Submitted by
logris on
Tuesday, 28 November, 2006 - 21:35
I am trying to write an edit mode for "JPL", the code behind a 4GL language called Panther and created by Prolifics. I have run into a problem that I cannot find a solution to and I would like to pose it to the JEdit community for any ideas.
Panther statements are newline terminated with a line continuation character. This seems to be the root of my problems. I would like to syntax highlight embedded SQL-like statements using keywords that only pertain to the embedded language. Here is an example of the embedded statement I would like to highlight:
// Call some function
call some_func()
// Begin the embedded SQL to highlight
DBMS SQL SELECT column \
FROM table \
WHERE column = 'Value'
// Do something else
for i= ...
The statement I want to highlight always begins with 'DBMS' and ends at the end of line, unless there is a line continuation character. There can be any number of continued lines. The statement ends at the end of the first line without a continuation character. For now, I will assume nothing can go after the continuation character (no comments).
Any ideas on how to match and delegate this statement to a seperate set of <RULES>? The best I have found so far is use <SEQ> to match the beginning DBMS statement and use <SEQ_REGEXP> to match on " [^\s\\]*$" with a hash character of " " for the end, but that tends to mess up my last token's highlighting.
Maybe there is a way to match on newline or detect the end of line? Or delegate when no more tokens are left on a line? Or match across a line?
Any help would be appreciated. Thanks. =)