No subject


Thu Oct 7 01:56:53 CEST 2010


The next code (adapted from marble source) is causing me some troubles.

  RoutingManager *routingManager =3D theMap->model()->routingManager();

RoutingModel   *routingModel   =3D routingManager->routingModel();

bool hasRoute =3D rModel->rowCount();


My includes are:

#include <marble/global.h>

#include <marble/MarbleModel.h>

#include <marble/RoutingManager.h>


The third line (in green) causes the compilation to fail with the error:

error: invalid use of incomplete type =E2=80=98struct Marble::RoutingModel=
=E2=80=99
As I have seen, the RoutingModel Class is defined (as Class RoutingModel;)
 in RoutingManager.h, but included in the ControlView.cpp file as ' #includ=
e
"routing/RoutingModel.h" ' .

Are the "routing"-folder headers  inside the marble lib sources not
installed (at /usr/include/marble) ?
Is this intentional, only for the Marble application (not the library) ?

What is the correct way to incorporate routing capabilities to another
application? What Classes to use, the ControlView, the RoutingManager?


Im using the marble code from the anonymous kde svn repository (svn://
anonsvn.kde.org/home/kde/trunk/KDE/kdeedu/marble/src).

Thanks in advance,

--=20
Miguel Chavez Gamboa

--001485ea873c58ecc00491fb8539
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

Hi,<div><br></div><div>Im trying to incorporate marble and its new offline =
routing capabilities in my own project, and Im reading the marble source co=
de and the documentation.</div><div>From the marble source code, i got some=
 code to start and experiment.</div>
<div><br></div><div>The next code (adapted from marble source) is causing m=
e some troubles.=C2=A0</div><div><br></div><div>
<table style=3D"-qt-table-type: root; margin-top:4px; margin-bottom:4px; ma=
rgin-left:4px; margin-right:4px;">
<tbody><tr>
<td style=3D"border: none;">
<pre style=3D" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-r=
ight:0px; -qt-block-indent:0; text-indent:0px;">RoutingManager<span style=
=3D" color:#c0c0c0;"> </span><span style=3D" color:#000000;">*</span>routin=
gManager<span style=3D" color:#c0c0c0;"> </span><span style=3D" color:#0000=
00;">=3D</span><span style=3D" color:#c0c0c0;"> </span>theMap<span style=3D=
" color:#000000;">-&gt;</span>model<span style=3D" color:#000000;">()-&gt;<=
/span>routingManager<span style=3D" color:#000000;">();</span></pre>

<pre style=3D" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-r=
ight:0px; -qt-block-indent:0; text-indent:0px;">RoutingModel   <span style=
=3D" color:#000000;">*</span>routingModel<span style=3D" color:#c0c0c0;">  =
 </span><span style=3D" color:#000000;">=3D</span><span style=3D" color:#c0=
c0c0;"> </span>routingManager<span style=3D" color:#000000;">-&gt;</span>ro=
utingModel<span style=3D" color:#000000;">();</span></pre>

<pre style=3D" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-r=
ight:0px; -qt-block-indent:0; text-indent:0px;"><span style=3D" color:#0080=
00;">bool</span><span style=3D" color:#c0c0c0;"> </span><span style=3D" col=
or:#008000;">hasRoute</span><span style=3D" color:#c0c0c0;"> </span><span s=
tyle=3D" color:#008000;">=3D</span><span style=3D" color:#c0c0c0;"> </span>=
<span style=3D" color:#008000;">rModel-&gt;rowCount();</span></pre>
<pre style=3D" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-r=
ight:0px; -qt-block-indent:0; text-indent:0px;"><span style=3D" color:#0080=
00;"><br></span></pre><pre style=3D" margin-top:0px; margin-bottom:0px; mar=
gin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">
<span style=3D" color:#008000;"><span class=3D"Apple-style-span" style=3D"c=
olor: rgb(0, 0, 0); font-family: arial; white-space: normal; -webkit-border=
-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; font-size: =
small; "><div>
My includes are:</div><div><br></div><div><table style=3D"margin-top: 4px; =
margin-bottom: 4px; margin-left: 4px; margin-right: 4px; "><tbody><tr><td s=
tyle=3D"border-top-style: none; border-right-style: none; border-bottom-sty=
le: none; border-left-style: none; border-width: initial; border-color: ini=
tial; ">
<pre style=3D"margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin=
-right: 0px; text-indent: 0px; "><span style=3D"color: rgb(0, 0, 128); ">#i=
nclude</span><span style=3D"color: rgb(192, 192, 192); "> </span><span styl=
e=3D"color: rgb(0, 128, 0); ">&lt;marble/global.h&gt;</span></pre>
<pre style=3D"margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin=
-right: 0px; text-indent: 0px; "><span style=3D"color: rgb(0, 0, 128); ">#i=
nclude</span><span style=3D"color: rgb(192, 192, 192); "> </span><span styl=
e=3D"color: rgb(0, 128, 0); ">&lt;marble/MarbleModel.h&gt;</span></pre>
<pre style=3D"margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin=
-right: 0px; text-indent: 0px; "><span style=3D"color: rgb(0, 0, 128); ">#i=
nclude</span><span style=3D"color: rgb(192, 192, 192); "> </span><span styl=
e=3D"color: rgb(0, 128, 0); ">&lt;marble/RoutingManager.h&gt;</span></pre>
</td></tr></tbody></table></div></span></span></pre></td></tr></tbody></tab=
le><br></div><div>The third line (in green) causes the compilation to fail =
with the error:</div><div>
<table style=3D"-qt-table-type: root; margin-top:4px; margin-bottom:4px; ma=
rgin-left:4px; margin-right:4px;">
<tbody><tr>
<td style=3D"border: none;">
<p style=3D" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-rig=
ht:0px; -qt-block-indent:0; text-indent:0px;"><span style=3D" color:#ff0000=
;">error: invalid use of incomplete type =E2=80=98struct Marble::RoutingMod=
el=E2=80=99=C2=A0</span></p>
</td></tr></tbody></table></div><div>As I have seen, the RoutingModel Class=
 is defined (as Class RoutingModel;) =C2=A0in RoutingManager.h, but include=
d in the ControlView.cpp file as &#39; #include &quot;routing/RoutingModel.=
h&quot; &#39; .</div>
<div><br></div><div>Are the &quot;routing&quot;-folder headers =C2=A0inside=
 the marble lib sources not installed (at /usr/include/marble) ?</div><div>=
Is this intentional, only for the Marble application (not the library) ?</d=
iv>
<div><br></div><div>What is the correct way to incorporate routing capabili=
ties to another application? What Classes to use, the ControlView, the Rout=
ingManager?</div><div><br></div><div><br></div><div>Im using the marble cod=
e from the anonymous kde svn repository (svn://<a href=3D"http://anonsvn.kd=
e.org/home/kde/trunk/KDE/kdeedu/marble/src">anonsvn.kde.org/home/kde/trunk/=
KDE/kdeedu/marble/src</a>).</div>
<div><br></div><div>Thanks in advance,</div><meta http-equiv=3D"content-typ=
e" content=3D"text/html; charset=3Dutf-8"><div><br></div><div>--=C2=A0</div=
><div>Miguel Chavez Gamboa<br>
</div>

--001485ea873c58ecc00491fb8539--


More information about the Marble-devel mailing list