Sort and filter stations in the station list window

Got an idea for OpenTTD? Post it here!

Moderator: OpenTTD Developers

Post Reply
ChrisHuebsch
Engineer
Engineer
Posts: 75
Joined: 10 Jun 2004 12:46

Sort and filter stations in the station list window

Post by ChrisHuebsch »

When there are too many stations it is becomes harder
and harder to keep an eye on each station.

This patch allows to sort and filter the station list.

Filtering: On top of the window are two sections. Left
the types of vehicles, right the type of cargo.
If one clicks on one of these buttons, only the
selected vehicle-type or cargo is selected for
filtering. If ctrl is pressed while clicking, more than
one vehicle-type/cargo can be selected. There is a
special cargo No. 13. It is the grey one on the far
right side. This cargo means "no cargo". (Eg. stations
only receiving cargo, but not producing.)

Sorting: In the second row there is a toggle-button to
change between ascending and descending. Possible sort-
types are:
Name, Type (of vehicle), Rating min/max (use the best/
worst rating of waiting goods) and waiting goods
(expected revenue if all of the waiting goods are
transported 20 fields away during 50 days).

Comments are appreciated.

The source of this patch can be found here:
http://sourceforge.net/tracker/index.ph ... tid=636367
Attachments
This is how the new station window looks like
This is how the new station window looks like
sort_and_filter.png (45.38 KiB) Viewed 6157 times
Last edited by ChrisHuebsch on 29 Dec 2005 18:14, edited 1 time in total.
User avatar
webfreakz.nl
Director
Director
Posts: 627
Joined: 11 Aug 2005 08:22
Location: Localhost, 127.0.0.1, [The Netherlands: South Holland-> Westland]
Contact:

Post by webfreakz.nl »

I like it!

Can you supply a fully working program with the patch, for people without compilers? :)
# Programming is like sex, one mistake and you have to support it for the rest of your life. (Michael Sinz)
ChrisHuebsch
Engineer
Engineer
Posts: 75
Joined: 10 Jun 2004 12:46

Post by ChrisHuebsch »

webfreakz.nl wrote:Can you supply a fully working program with the patch, for people without compilers? :)
Sorry. I cannot. I only use Linux and can only make linux-binaries.
I someone can compile some binaries, it would be great.

There are changes in the lang-files. So one has to include a new english.lng!
richk67
Tycoon
Tycoon
Posts: 2363
Joined: 05 Jun 2003 16:21
Location: Up North
Contact:

Post by richk67 »

Nice patch. If you are happy for it to be included in the Integrated Nightly, I will add it to the next build.

Thanks - this is something Ive wanted for ages. It is a royal pain on a BIG map when you have 250+ stations, and are looking for that lorry depot with excess mail..
OTTD NewGRF_ports. Add an airport design via newgrf.Superceded by Yexo's NewGrf Airports 2
Want to organise your trains? Try Routemarkers.
--- ==== --- === --- === ---
Firework Photography
User avatar
osai
Traffic Manager
Traffic Manager
Posts: 132
Joined: 22 Sep 2004 14:56
Location: 10.0.1.254
Contact:

Post by osai »

Cool patch, I like it too!
Especially on big maps it can be really useful.

But for the CargoType "Coal" you should use white text, otherwise you can not read it!
User avatar
belugas
OpenTTD Developer
OpenTTD Developer
Posts: 1507
Joined: 05 Apr 2005 01:48
Location: Deep down the deepest blue
Contact:

Post by belugas »

Here is the win32 binary, along with a little bonus, the french translation patch and french language file.
Attachments
Sort_And_StationWinBinary.zip
openttd.exe
french and english language file
french translation patch
(476.33 KiB) Downloaded 172 times
sort_and_filter2_1.patch
New version, with Tron's correction of STR_SORT
French updated too
(25.78 KiB) Downloaded 210 times
Last edited by belugas on 30 Dec 2005 18:51, edited 1 time in total.
If you are not ready to work a bit for your ideas, it means they don't count much for you.
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
ChrisHuebsch
Engineer
Engineer
Posts: 75
Joined: 10 Jun 2004 12:46

Post by ChrisHuebsch »

richk67 wrote:Nice patch. If you are happy for it to be included in the Integrated Nightly, I will add it to the next build.
It would be great. Where can this "Integrared Nightly" can be found? I'd like to point some friends to it.
MeusH
Tycoon
Tycoon
Posts: 4349
Joined: 25 Oct 2004 15:39
Location: Mississauga

Post by MeusH »

ChrisHuebsch, please submit it to http://bugs.openttd.org/ - chance of having it in OTTD after 0.4.5 will increase
Tron
OpenTTD Developer
OpenTTD Developer
Posts: 57
Joined: 13 Dec 2004 23:15

Post by Tron »

MeusH wrote:ChrisHuebsch, please submit it to http://bugs.openttd.org/ - chance of having it in OTTD after 0.4.5 will increase
The chance for any further new feature before the next release is zero. There are enough problems with broken features, which never got finished, at the moment and we're busy with cleaning up that mess.

<edit>
Sorry, somehow i read "before" instead of "after"
</edit>
ChrisHuebsch
Engineer
Engineer
Posts: 75
Joined: 10 Jun 2004 12:46

Post by ChrisHuebsch »

MeusH wrote:ChrisHuebsch, please submit it to http://bugs.openttd.org/ - chance of having it in OTTD after 0.4.5 will increase
The patch is in one place: the sf.net-repo. It can be easily downloaded if there is any interest in it.
I think it is not good to have a patch duplicated to more than 1 location.
Tron wrote: The chance for any further new feature before the next release is zero. There are enough problems with broken features, which never got finished, at the moment and we're busy with cleaning up that mess.
I do not have time to reprogramm it again and again to have that patch in sync with the svn-repo. Last time I did that in summer 3 or 4 times. I think that is enough.
User avatar
belugas
OpenTTD Developer
OpenTTD Developer
Posts: 1507
Joined: 05 Apr 2005 01:48
Location: Deep down the deepest blue
Contact:

Post by belugas »

I upgraded win binary posted earlier.
It is now made from sort_And_FilterStation2.patch, plus a little correction due to Tron's STR_SORT correction.
As usual, french is translated too...
If you are not ready to work a bit for your ideas, it means they don't count much for you.
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
Post Reply

Return to “OpenTTD Suggestions”

Who is online

Users browsing this forum: No registered users and 12 guests