Quick ColdFusion Builder Tip: Split Panes
Here's a tip I just figured out for myself this morning, out of necessity. Have you ever wanted to work on one section of a file while looking at another section, hundreds of lines up or down? Scrolling back and forth is a nightmare.
Other editors offer what is called a Split Pane, where you can take the currently open file and divide the window in half, each showing the same file, but each with its own independent scroll bar. Doing this, you can have one section of code in-view, and another that you're working on. This is incredibly helpful.
It's not immediately obvious, but you can do this in Eclipse, and therefore in CFBuilder, too.
The first thing you need to do is clone the tab that you want to split. To do this, choose Window > New Editor from the menu. This will open a 2nd editor (tab) containing the same file, but it won't be split. These two tabs are linked -- changes you make in one are also made in the other.
Next, drag the tab for this new editor to the side of the Eclipse window you want to split. As your mouse approaches the edge of the pane, it will change to an arrow, and there will be a shaded border filling about half the pane, indicating that if you drop it where it is, the editor will fill that border area. Drop it there.
You can split horizontally, as I have here, because I have an enormous monitor and plenty of room:

Or you can also split vertically, if you don't have the horizontal screen space:

Update:
Although it's possible to create split panes as I've illustrated here, the functionality is kind of buggy. If you just need to view or compare 2 sections of the same file, this could be useful; but trying to edit the file in one of the panes seems to cause some strange issues with syntax highlighting, your cursor may disappear, and the pane may just freeze up. I've filed a bug for this behaviour, which I would encourage you to vote for if this feature is important to you. Hopefully this issue will get resolved in a future update.
Posted in CFBuilder | 4 Responses
4 responses:
- Brian Swartzfager Apr 28, 2010 at 10:47 AM Good tip. I've opened up new editor panes so I could compare the code in two different files, but it never occurred to me to try and view the same file in a similar fashion.
- Sagar Ganatra Jun 23, 2010 at 1:31 AM Are you still facing this issue? I was looking into this and it worked fine for me.