[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-09 Thread noreply
The proposal to merge lp:~widelands-dev/widelands/doc_type_name into 
lp:widelands has been updated.

Status: Needs review => Merged

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
-- 
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-09 Thread GunChleoc
Thanks for finishing this up :)

@bunnybot merge
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-04 Thread SirVer
This is a test, please ignore.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-03 Thread kaputtnik
Done.

I think this is ready to go now?
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-03 Thread GunChleoc
I think that's a good idea and I agree with the phrasing. I won't get to it 
before the weekend, would you like to take care of it?

"You cannot instantiate this directly, access it via wl.Game().map.get_field() 
instead."
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-02 Thread bunnybot
Continuous integration builds have changed state:

Travis build 2499. State: passed. Details: 
https://travis-ci.org/widelands/widelands/builds/259871581.
Appveyor build 2323. State: success. Details: 
https://ci.appveyor.com/project/widelands-dev/widelands/build/_widelands_dev_widelands_doc_type_name-2323.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-01 Thread kaputtnik
Nice :-)

I did some additional syntax fixes for wl.map.Warehouse.

There is one issue left from my side:
I the Fields section one could read: "You cannot instantiate this class 
directly, instead use wl.map.Map.get_field()." See:
  https://wl.widelands.org/docs/wl/autogen_wl_map/#field

The link points to wl.map.Map.get_field(), and only after scrolling up to the 
description of wl.map.Map one could read: "You cannot instantiate this 
directly, instead access it via wl.Game.map.". See: 
  https://wl.widelands.org/docs/wl/autogen_wl_map/#map

This too complicated and not understandable, additionally the last sentence is 
imho wrong. Shouldn't it be "... via wl.Game().map." (additional brackets)?

Anyway, since we are working here on wl.map, i would suggest to turn the 
sentence in wl.map.Field into something like: "You cannot instantiate this 
directly, instead access it via wl.Game().map.get_field()", or show a code 
example?
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-08-01 Thread GunChleoc
Thanks for digging that one up! All linked now :)

I think we still have too much asymmetry between objects and their descr, but 
that can't be helped without exposing the rest to the Lua interface, which I'd 
say is out of scope for this branch.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-31 Thread kaputtnik
I get it to work, see http://ibb.co/ecziaQ

If you are fine with my wording i will change the other occurrences according 
to this example.

To get this working i just used another "role" called :any:. This searches for 
all parts wich has a clickable header in the documents. One could use parts of 
the link shown in the tooltip of the header (the address of the link). One has 
to pay attention that the used part is unique over all documents, otherwise an 
error occur. I used now the ResT-code:

 You can access further properties via :any:`MapObject.descr`
 to access the attributes of :class:`ImmovableDescription`.

All ResT code which is like: 

.. FooBar::

are turned into clickable links, so they can be used for linking.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-31 Thread bunnybot
Continuous integration builds have changed state:

Travis build 2490. State: errored. Details: 
https://travis-ci.org/widelands/widelands/builds/259384065.
Appveyor build 2314. State: success. Details: 
https://ci.appveyor.com/project/widelands-dev/widelands/build/_widelands_dev_widelands_doc_type_name-2314.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-31 Thread GunChleoc
I spent an hour RTFM and it looks like we can't link to MapObject:descr with 
Sphinx. I ran out of time, so I'll have to try again some other time. If 
somebody else figures this out in the meantime, it won't hurt my feelings :P
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-30 Thread bunnybot
Continuous integration builds have changed state:

Travis build 2488. State: failed. Details: 
https://travis-ci.org/widelands/widelands/builds/259145374.
Appveyor build 2313. State: success. Details: 
https://ci.appveyor.com/project/widelands-dev/widelands/build/_widelands_dev_widelands_doc_type_name-2313.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-30 Thread kaputtnik
This looks much better now :-)

One nit: There are now several statements like:

"You can access further properties via its descr."

The word 'its' let me assume that 'descr' is a property of the linked objects, 
but there is no such property. Maybe clarify the statement to something like:

"You can access further properties via  from which you 
get access to "
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-30 Thread GunChleoc
Review: Resubmit

I have made the documentation more detailed now, added a couple of links and 
documented the type hierarchy by linking. Also fixed the bugs that kaputtnik 
found.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-30 Thread GunChleoc
The proposal to merge lp:~widelands-dev/widelands/doc_type_name into 
lp:widelands has been updated.

Commit Message changed to:

Fixed and improved documentation for LuaMapObjectDescription::get_type_name. 
More cross-linking between map object classes and their description objects. 
Fixed some miscellaneous bugs in the LuaMap documentation.

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
-- 
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-30 Thread GunChleoc
That links to how to define a tribe... it would be more useful to have a 
reference to the properties that can be queried at runtime in 
https://wl.widelands.org/docs/wl/autogen_wl_map/#module-classes, link to class 
wl.map.ImmovableDescription etc.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-28 Thread kaputtnik
> We could link them to the LuaDescription objects, 
> which already have documentation about he building types etc.

Don't know what you mean here :-S E.g. this page: 
https://wl.widelands.org/docs/wl/autogen_toc_lua_tribes_buildings/ ?

Creating a documentation which is useful for beginners is not easy... I am 
mostly lost in the current documentation. Maybe an image showing some sort of a 
class hierarchy would be helpful.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-27 Thread GunChleoc
We could link them to the LuaDescription objects, which already have 
documentation about he building types etc.

No resubmit needed unless you want to send a diff to the mailing list or signal 
a big change.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-25 Thread bunnybot
Continuous integration builds have changed state:

Travis build 2476. State: passed. Details: 
https://travis-ci.org/widelands/widelands/builds/257274323.
Appveyor build 2301. State: success. Details: 
https://ci.appveyor.com/project/widelands-dev/widelands/build/_widelands_dev_widelands_doc_type_name-2301.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-25 Thread Klaus Halfmann
Sorry for the extra commit, using this Ubuntu on Win is a pian.
OTOH I build the shinx Docs now, and found my comment there.

Gun: will we need a resubmint?
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-25 Thread GunChleoc
Yes, your comment is correct.

We still lack documentation for the world objects, so feel free to add it here.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-25 Thread Klaus Halfmann
Review: Approve review

Since this is no code change there is no sense in compiling this.
All fine foe me, ther mor docs the better.

If my inline comment abot critter is correct I will iclude it.

Diff comments:

> 
> === modified file 'src/scripting/lua_map.cc'
> --- src/scripting/lua_map.cc  2017-06-24 08:18:48 +
> +++ src/scripting/lua_map.cc  2017-07-25 07:00:49 +
> @@ -1616,9 +1616,18 @@
>  }
>  
>  /* RST
> -   .. attribute:: type
> -
> - (RO) the name of the building, e.g. building.
> +   .. attribute:: type_name
> +
> + (RO) the map object's type as a string. Possible values are:
> +
> + * Bobs: ``bob``, ``critter``, ``ship``, ``worker``, ``carrier``, 
> ``soldier``
> + * Wares: ``ware``
> + * Immovables: ``immovable``
> +
> +* Buildings: ``building``, ``constructionsite``, 
> ``dismantlesite``, ``warehouse``, ``productionsite``, ``militarysite``, 
> ``trainingsite``
> +* Other: ``flag``, ``road``, ``portdock``
> +

'critter' are the animals on the map (not including Donkye, Horse, Oxen, as 
they are carriers).
If this is corerct I would like to add this (did not know what critters are 
till now).

> + * Other: ``battle``, ``fleet``
>  */
>  int LuaMapObjectDescription::get_type_name(lua_State* L) {
>   lua_pushstring(L, to_string(get()->type()));


-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is subscribed to branch 
lp:~widelands-dev/widelands/doc_type_name.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-25 Thread GunChleoc
You're right - I don't know when I gan get to it though.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/doc_type_name into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


Re: [Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-25 Thread kaputtnik
Since your on it, the documentation in 

https://wl.widelands.org/docs/wl/autogen_wl_map/#immovabledescription

looks messed up.
-- 
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/doc_type_name into lp:widelands.

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp


[Widelands-dev] [Merge] lp:~widelands-dev/widelands/doc_type_name into lp:widelands

2017-07-25 Thread GunChleoc
GunChleoc has proposed merging lp:~widelands-dev/widelands/doc_type_name into 
lp:widelands.

Commit message:
Fixed and improved documentation for LuaMapObjectDescription::get_type_name.

Requested reviews:
  Widelands Developers (widelands-dev)

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/doc_type_name/+merge/328006
-- 
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/doc_type_name into lp:widelands.
=== modified file 'src/logic/map_objects/map_object.cc'
--- src/logic/map_objects/map_object.cc	2017-06-25 08:20:25 +
+++ src/logic/map_objects/map_object.cc	2017-07-25 07:00:49 +
@@ -619,6 +619,7 @@
 }
 
 std::string to_string(const MapObjectType type) {
+	// The types are documented in scripting/lua_map.cc -> LuaMapObjectDescription::get_type_name for the Lua interface, so make sure to change the documentation there when changing anything in this function.
 	switch (type) {
 	case MapObjectType::BOB:
 		return "bob";

=== modified file 'src/scripting/lua_map.cc'
--- src/scripting/lua_map.cc	2017-06-24 08:18:48 +
+++ src/scripting/lua_map.cc	2017-07-25 07:00:49 +
@@ -1616,9 +1616,18 @@
 }
 
 /* RST
-   .. attribute:: type
-
- (RO) the name of the building, e.g. building.
+   .. attribute:: type_name
+
+ (RO) the map object's type as a string. Possible values are:
+
+ * Bobs: ``bob``, ``critter``, ``ship``, ``worker``, ``carrier``, ``soldier``
+ * Wares: ``ware``
+ * Immovables: ``immovable``
+
+* Buildings: ``building``, ``constructionsite``, ``dismantlesite``, ``warehouse``, ``productionsite``, ``militarysite``, ``trainingsite``
+* Other: ``flag``, ``road``, ``portdock``
+
+ * Other: ``battle``, ``fleet``
 */
 int LuaMapObjectDescription::get_type_name(lua_State* L) {
 	lua_pushstring(L, to_string(get()->type()));

___
Mailing list: https://launchpad.net/~widelands-dev
Post to : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp