Version 1.3 of Quick Bookmarks is out, providing the following new features:

Shortcuts for navigation across files: In addition to the the keyboard shortcuts for navigation between bookmarks in the current file (Alt+PgUp/PgDn by default), shortcuts for navigation through all bookmarks in the current project and the current workspace are now available. Bookmark navigation across the entire workspace is bound to Alt+Shift+PgUp/PgDn by default. Thanks to David Ei and LarsWH for suggesting this feature.

Quickmarks: Alt+Home will set a quickmark at the current position. Pressing Alt+Home again will jump back to the quickmark and delete it.

Jump to file: Pressing Shift+Return (or using the context menu) in the bookmark popup dialogue can be used to jump to the file containing the selected bookmark without changing the cursor position in that file.

Sort bookmarks list by resource: The bookmark popup dialogue’s context menu can now be used to switch between ordering bookmarks chronologically (the standard behaviour) and sorting them by resource.

For installation instructions, please see here. As always, feedback is welcome.

A third page was added to the popup dialogue listing all bookmarks from the workspaces. The selected bookmark list in the dialogue is now remembered even when restarting Eclipse.

Bookmarks store the editor type they were set in. For example, when opening an HTML file in a text editor and setting a bookmark, then reopening the same file in browser mode, jumping to the bookmark will jump to the text editor instead of the browser.

For installation instructions, please see here. As always, feedback is welcome.

For years I’ve been missing simple bookmarks in Eclipse – bookmarks that can be quickly toggled and navigated via the keyboard, like I remember them from Delphi all those years ago.

Now I decided to do something against it and wrote another simple plug-in: Quick Bookmarks.

It doesn’t do much – just provide a keyboard shortcut to add or remove a bookmark from the current editor line, and two shortcuts to jump to the previous or next bookmark relative to the current line. The bookmarks created by the plug-in are sub types of the standard Eclipse bookmarks, but you don’t have to enter a name every time you create a new bookmark.

Over the past weeks I’ve made several bug fixes to Grep Console and Tail Console. In the case of Clippets, I’ve added new few features.

Grep Console’s popup notification implementation is now also used by Clippets and therefore has been moved to its own plug-in. Eclipse will automatically install the new plug-in when installing or updating to the latest versions.

As always, feedback is welcome.

Grep Console 3.6.1

This is a bugfix release, containing the following fixes:

Disablement of items not stored – Disabled items were enabled again after reloading the configuration. Folderes were unaffected. Thanks to Thomas Widmaier for reporting this bug.

Wrong style ranges for overlapping highlighting styles – Overlapping styles ended one character too early, leaving the last matched character unstyled. Thanks to 赛文思 for reporting this bug.

File link path and base dir not handled correctly – Absolute file paths were not recognised correctly and would always be prefixed with the base directory. Some Eclipse variables return file: URIs. These are now automatically converted to regular file paths. Thanks to 赛文思 for reporting this bug.

Clippets 1.1.0

This is a feature release, containing the following improvements:

Styles – Clippets can now be assigned styles to change the foreground and background colours shown in clippet lists.

Clippet collection memory – The clippet selection popup by default now opens with the last clippet collection that was selected. Changing the collection also updates the Clippet View. Both features can be deactivated in the preferences.

Popup notifications – To provide feedback with some of the “blind” actions (e.g. recalling clippets via keyboard shorcuts), certain actions now trigger notification popup notifications. These popups can be disabled in the preferences.

Inserting clippets – A new action (triggered e.g. by double clicking a clippet) directly inserts the selected clippet into the current editor without changing the clipboard content. Thanks to Robert Mark Bram for suggesting this feature.

Store to selection in popup – Pressing Shift+Enter in the clippet storing popup dialogue now stores the clipboard content into the selected clippet. Thanks to Robert Mark Bram for suggesting this feature.

Tail Console 1.0.1:

Popup Notifications 1.0:

This is a helper plug-in. It doesn’t offer any active end user features on its own. Instead, it provides an API to display popup notifications that automatically disappear after a short moment. The plug-in is used by both Grep Console and Clippets and may be used in other projects under the terms of the Eclipse Public Licence.

Doesn’t look so bad, but in fact the touch screen is completely dead. So not only do I now have to decide whether to get a new phone or try to replace the screen myself, I also had to find a way to regain control over the phone so I could backup my data.

A bluetooth mouse would be one way to control the phone without the touch screen, but I don’t have one – and even if I did, I didn’t have bluetooth turned on (though that could apparently be accomplished through the console).

A USB keyboard would also be of help if the Nexus 4 had USB Host support. Sadly, unlike the Nexus 5 (and the Nexus 1, if I recall correctly), doesn’t.

What else then? A series of internet searches yielded the following results:

There’s a ton of remote control apps for Android (as was to be expected). Most require root though. Those that don’t generally can’t control the touchscreen/mouse. And even they generally require some setup steps before they can be used – back to the start.

adb (the Android Debug Bridge, part of the SDK tools) provides shell access to the phone via USB. And the shell has commands to simulate key presses and touchevents. Touch events require the exact screen coordinates as numbers, so as a standalone solution that’s still rather tedious.

There are ways to get screenshots from an Android phone through adb – obviously; after all, even the official Eclipse plug-ins provide a screenshot feature.

A combination of points 2 and 3 would be a way to actually simulate touch events in a useful manner. Astonishingly though, nobody seems to have written such a tool.

So what does a programmer to when the obvious tool doesn’t yet exist? Write it himself, of course.

ADB Control

I spent yesterday evening hacking together a crude Java tool to serve as a primitive remote control through an Android phone. I present it here in case someone else might face the same problem I did. It requires no extra software installed on the phone, just a USB connection and the Java tool (Java 7 required) and SDK tools installed on the computer. It uses adb access to the phone – meaning that you have to have the SDK tools installed and you have to have already confirmed the USB debug connection on your phone earlier. If you didn’t, connecting the phone will open a confirmation dialogue on the phone – and without a touchscreen, you obviously won’t be able to confirm it. But if you’re a programmer like me and have already access the phone via adb before, all you have to do is fire up the tool on the computer. I won’t get into how to setup and configure adb here – please check the official docs if necessary.

The tool does the following:

Repeatedly grab a screenshot from the phone and display it in a Window

Capture keyboard events and forward them to the phone

Capture mouse clicks and drags and forward them to the phone

It’s slow as hell (everything is being done through shell calls, which makes the screenshot updates particularly slow), but it works.

Before you first start it, make sure you have adb installed and modify the config file provided with the download. It contains four settings:

adbCommand – the full path to the adb tool as a shell command. Linux users note that Java doesn’t seem like the ~ character in file paths to access the home directory.

screenshotDelay – the delay (in milliseconds) between displaying a screenshot and grabbing the next one. Note that the actual grabbing process will probably take considerably longer than this delay, so the update rate will be slower.

localImageFilePath – the tool has to download the image file from the phone. This path tells it where to store the file on the local system before displaying it.

phoneImageFilePath – the location on the phone where the screenshot file is stored before downloading it.

Once the configuration is done, simply run the tool like this:

java -jar adbcontrol.jar

If you put the config file in a different directory, you can add the path to it as an option after the jar file name.

Here’s what it looks like:

In the window, you can single click to send a tap event or click-drag to send a swipe event to the phone. Pressing a number or letter key (or anything else that produces an ASCII character between 33 and 127) will send that key press to the phone. Additionally, the following keys are forwarded:

It’s been a while since the last update, but there finally is a new version of Grep Console, providing bug fixes and a new feature.

Features:

Statistics – Expression occurences can be counted and displayed in a separate view. Also, the last match for an expression can be displayed in the same view. Based on a feature suggestion by Frank Musolf.

Bug Fixes:

When an item has a null name and expression, the item table throws null pointer exceptions. Reported by Thomas Klimke.

Grep View should be cleared when the console is cleared. Reported by Thomas Dutreuilh.

Also, because it has been such a frequent cause of confusion, the default match length for Grep View matching has been increased to 100.

As usual, thanks go to everyone who sent suggestions and bug reports to help continue improving Grep Console.

For installation instructions, please see here. As always, feedback is welcome.

New Plug-in: Tail Console

Jakub Staš suggested allowing Grep View to open random text files. Instead of implementing this as a Grep Console feature, I turned it into a separate plug-in.

Tail Console can open text files and output them to a new console. Like the GNU command line tool tail, the console will keep monitoring the file and output any new content added to the file live.

Tail Console is fully compatible with Grep Console (in its latest version), so using both plug-ins together, text files can be styled and filtered as usual with Grep Console.

New Plug-in: Clippets

This is based on an idea I’d been thinking about for a long time. Clippets allows you to store the current clipboard text content inside Eclipse, temporarily or permanently, and later recall it directly to the clipboard, allowing you to use the clipboard for other content and then return to the earlier text. These so-called “clippets” can be arranged in collections for better overview.

I have several ideas for extending Clippets with advanced features, but before I think about them in detail, I’d like to see what others think about the core functionality – and get used to working with it myself. So if you like the plug-in and have any feedback or feature suggestions, be sure to let me know!

Getting C++11 to work with CMake is easy. Getting Eclipse to work with a CMake project is easy. Getting Eclipse to work with C++11 also seems to be relatively easy (there are plenty of guides on various wikis).

But getting all three to cooperate nicely is a bit trickier – or rather, the standard Eclipse way to configure C++11 support doesn’t work for CMake projects, and none of the guides I could find at first mentioned that.

It’s perfectly possible to work with a C++11 CMake project in Eclipse without any special settings. Compiling and running the code works fine (as the compiler gets its settings from the CMake config), but the code editor will keep mark various C++11 code bits as errors.

Fortunately, this Stack Overflow post shows how easy it is to fix this for Eclipse Kepler if you just know the right option to set. Simply create your Eclipse project with something like this: