[Eclipse] Better way of organising Package Explorer?

To my surprise, there isn’t much information out there on how to organise Packages in the Eclipse. I don’t mind the tree view, but my problem is that I have just gotten into doing LibGDX work, and it’s a pain in the butt having 100 different packages on the package explorer and having to find my LibGDX projects.

Is there a way that I could say for example have all general Java programming in one folder in the Package explorer, and LibGDX related stuff in another folder, then if I want to access all my LibGDX projects, I can expand the LibGDX folder?

I am not sure if this really makes sense to people reading as I exhausted from work, but it’s just been a pet peeve of mine since I noticed the more I studied Java, the more my project explorer got cluttered and the harder it was to find what I was after.

Thanks in advance.

Also, I have spent several hours googling and looking on these forums to try and find some sort of solution which didn’t involve installing seperate plugins and such, but by the looks of things, I might have to.

You can switch work spaces, create a new folder somewhere, and press switch work space under file.

I think this is the only way or at least the easiest.

If you don’t mind tree view, then create Working Sets. Working sets are kind of wrapping some of the projects. You have only one workspace, but you can have three(as many as you want) working sets. For example, I created three working sets, one includes pure java stuff, one includes android stuff and another is for gaming stuff.

There is an arrow in the top right corner of your package explorer. An arrow looking down (Popup tip says: View Menu). You’ll probably figure it out.

If you do this, you will have one big work space, all of your projects will be in the same folder. But it will show different in Eclipse.

One thing to be careful about is, when adding a new project, you have to define its working set as well. Or else it won’t have one, hence won’t show up.

Thanks guys, muchly appreciated.

I actually fiddled around before making this post, and managed to select different projects to put into a new working set, but I didn’t change what to be viewed in the explorer, so everything was still showing up and I was wondering what the hell I was doing wrong :stuck_out_tongue:

Once again though guys, I really appreciate it, you just saved me a whole lot of buggering around and also many hairs on my head that were scared of being ripped out. :stuck_out_tongue:

Use Projects, Packages, Types. 3 smaller views, more efficient that Package Explorer.

That looks interesting and a little confusing, it’d probably take a little bit of adjustment for me to get used to it, but holy hell, did you turn a 27" monitor on it’s side or something? :stuck_out_tongue:

30" :smiley: I miss it, been traveling with a laptop for 2 years. It’s a massive M18x laptop with an 18.5" screen, but it’s no 30" screen. :frowning:

I’ve been using the 3 views for so long, I can’t remember anymore. 8 years? It’s a really nice way to navigate Java. Using a tree wastes space and horizontal scrolling is horrible, horrible.

I have nothing to add, unfortunately, but wanted to say thanks for this question, and the answers. I’ve not came across a lot of solid info regarding customisation of Eclipse, so this was a bit of gold for me! :slight_smile:

Cheers!

Nate this looks perfect.

I won’t turn my 22" ‘small’ monitor on its side, but I’ll try to get the same look. It’s wider, it’ll be better. I will have to scroll one day of course :stuck_out_tongue: But even you with that awfully long view had to scroll.

Separating packages and projects is nice. I just tried it but packages view showed imported classes as well. And I am looking into libgdx, so there were tons of imports. How did you get it not to show the imported stuff?

BTW, if you spend much time on Eclipse, consider getting a dark theme.

Yeah, I’ve modified eclipse a little so that the white background on the text is not so white, more a yellowy white skin colour now so my eyeballs don’t burn out :stuck_out_tongue:

I also wear some gunnar glasses which help immensely, there is no way I could do 12 hour programming sessions without them and not having burning, irritated eyes that feel horrible and cause headaches and other annoyances. I’d highly recommend to get yourself some gunnar glasses, or at least some kind of glasses to reduce high intensity light.

I have a 3 monitor set up, 1 x 27" but it’s 1920x1080 (I just wanted to see if it fit on the desk, then return it to the store I got it :stuck_out_tongue: and then get a higher resolution, super duper expensive one, but kept the monitor instead and forgot about a high resolution one).
And I have 2 x 23" on either side.

I haven’t quite worked out how I want to use them just yet. I normally have my browser on the right side for when i’m studying or following tutorials. My main workspace is in the middle monitor obviously, and console takes up about 4/5 of the screen on the left. So just trying to work out what other things I can fill the space with :slight_smile:

With the 3 views, if you click a project sometimes it shows you more packages than you want. In that case, click a source folder under the project to see only packages there.

There is one little quirk, if you click a view (eg the console), the packages and types views go blank. This is because they are linked to the current source file, and when you click a non-source file view they have nothing to show. Just click the source editor and they come back. Since you are most often working with files in the same package or project, it is usually only 1 or 2 clicks to get the file you want, and usually there is zero scrolling involved.

There are also some settings:

You can filter the packages you see by clicking the little triangle in the Packages view. I always check filter empty packages and a flat package presentation.

In the Projects view filter settings I check libraries from external and libraries in project. This hides JARs under each project. You can also put in a filter separating with commas, eg “*.jar, config, *.zip, gen, resources, assets”. Use this to hide classpath folders you don’t want to look at, since you will be using this view for browsing Java classes.

I think it’s been proven that a white background with black text is better for your eyes. I’ve never had a problem with brightness, not even with 16 hour days (which are most days…). You should be sure to have bright light above and slightly behind you.

I used to use multiple monitors but I found I like a single gigantic monitor better.

I think it’s probably better to have one single monitor that is massive than multiple monitors because you’re not constantly looking left and right (which can get a bit tiresome after a while, especially when watching youtube tutorials on the right or left.

I mainly got 3 monitors for 3D modelling and animation work, it really helps when it comes to 3d modelling work :slight_smile:

Non-antialiazed font looks awful. :confused:

I disagree. :slight_smile: That is a bitmap font I call Lava Mono. It was originally BitStream Vera Mono rasterized to bitmap, then I tweaked pixels in the glyphs until it didn’t annoy me anymore. I like the clarity of it at small font sizes, where antialiasing just looks blurry. Also it has a very short line height, so I get more vertical lines than any other font. It’s here if anyone wants it.

At higher font sizes for higher resolution displays I have switched to using Consolas. It is really a great font! Trust me, I’ve evaluated almost every monospace font, ever. :slight_smile: I still use Lava Mono for my console, where the small size is fine and I appreciate seeing more vertical lines.

Dejavu Sans Mono.

Not as good as Consolas. Give it a try! :smiley:

I’ve tried both, DejaVu Sans Mono wins hands down for me :smiley:

They are both the same height and line height, but Consolas glyphs are not so freaking wide and are just as readable. Here is DejuVu Sans Mono on top and Consolas on bottom (click for actual size):


http://i.imgur.com/U3I45aM.png

This looks like two different font sizes?

Nope, same size (9). Note they are the exact same height, DejaVu Sans Mono is just super thick and wide. I set my code to wrap at 130 columns. With DejaVu those 130 columns take 167 pixels more width than Consolas, which would make my console and other tool views too small on my 1920x1080 laptop screen.