aspose file tools*
The moose likes IDEs, Version Control and other tools and the fly likes Split screen editor in Eclipse? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "Split screen editor in Eclipse?" Watch "Split screen editor in Eclipse?" New topic
Author

Split screen editor in Eclipse?

Gary Udstrand
Greenhorn

Joined: Jul 09, 2003
Posts: 1
I am currently using IntelliJ and their implementation does allow split screen editing. The problem is that it is limited to the same file.
Does Eclipse have a split screen editor? If so does it allow you to have multiple files opened?
Thanks
-Gary
Faisal Khan
Ranch Hand

Joined: Jun 29, 2003
Posts: 285
I am no expert in Eclipse, actually a total beginner but am getting to grips with it. It is indeed possible to split windows and open multiple files at once and as they say get it straight from the horse's mouth, here is what the tutorial on editors tells you:
"You can stack editors in the editor area and activate individual editors by clicking the tab for the editor. You can also tile editors side-by-side in the editor area so their content can be viewed simultaneously. In the figure below editors for sample.txt and otherFile.txt have been placed one above the other. We will discuss how you can rearrange views and editors later in this tutorial."


The secret to creativity is knowing how to hide your sources.
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
Does Eclipse have a split screen editor? If so does it allow you to have multiple files opened?

Yes. Eclipse allows split screen editing on multiple files but I believe you can't open the same file in two editors at the same time.
The split screen is achieved by the following:
1) Open multiple files (e.g. Controller.java, View.java and Model.java). They should now be stacked using tabs and the latest file, say Model.java, being "active".
2) Now left-click (don't release) on a "View.java"'s tab, drag the cursor to the lower edge of the active editor, wait a second so that the cursor changes into a black filled arrow, and release the mouse button. Voila, the two files (Model.java and View.java) should be now vertically split.
3) Now left-click (don't release) on "Controller.java" tab, drag the cursor to the right edge of one of the already open editors, wait a second so that the cursor changes into a black filled arrow, and release the mouse button. Voila, all three files are split into the screen.


Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Michael Zalewski
Ranch Hand

Joined: Jun 10, 2002
Posts: 30
You can open the same file twice.
Do Window | New Window, then open the source file in each window. What you type in one window appears in the other as you type.
But this is not a 'split window' like IntelliJ. However, it provides some of the same functionality. For example, you can scroll the first window to where your fields are declared, and the second window can be positioned at the method you are working on. Then you can add new fields to the first window, and add code to the second window. Saving from either window saves both changes.
Lasse Koskela
author
Sheriff

Joined: Jan 23, 2002
Posts: 11962
    
    5
Do Window | New Window, then open the source file in each window. What you type in one window appears in the other as you type.

Thanks, Michael. I hadn't tried that.
Ed Burnette
Author
Ranch Hand

Joined: Jun 10, 2003
Posts: 142
There's an open enhancement request that you can vote for:
http://bugs.eclipse.org/bugs/show_bug.cgi?id=8009


Ed Burnette, Author of Hello Android
Blog: ZDNet's Dev Connection - Twitter: @eburnette
Bill Zelan
Ranch Hand

Joined: Jan 09, 2009
Posts: 46
Managed to find this video which helped me a lot. Figured I'd post this here as it's one of the top results from Google on this topic.

http://vimeo.com/2862316?hd=1
Jeffrey Tian
Ranch Hand

Joined: Jun 02, 2010
Posts: 34
I found a way to open same file in different editor window.
. Right click the file name(it's also the tab title)
. Select New Editor, then you have 2 files with the same name opened in the same window.
. Drag one file to other window.

In this way, you can open the same file more than twice in different windows or the in same window. You edit in one window, copies in other windows will be modified simultaneously.
Isaac Saito
Greenhorn

Joined: Jul 14, 2011
Posts: 1
Jeffery's idea works out perfect. Thanks!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Split screen editor in Eclipse?