<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">Hi Andreas and Michael<br>
      <br>
      Working on the embedded group bug right now btw.<br>
      <br>
      >For layers, there is the layerIsEmbeded method of the
      QgsProject class, but what about groups ?<br>
      <br>
      There is no such method for groups, because QgsProject does not
      know anything about groups. Only the legend knows about groups,
      and there is a C++ method QgsLegend::groupEmbedded, but without
      python bindings in the legend interface.<br>
      <br>
      <br>
      Regards,<br>
      Marco<br>
      <br>
      On 19.02.2014 10:07, kimaidou wrote:<br>
    </div>
    <blockquote
cite="mid:CAMKXKO6JF1pTPCX4TxTi731B7znkwO87CBiVZ_M8q63uVNVT8w@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>
          <div>Hi,<br>
            <br>
            Another question regarding the embeded groups. Is there any
            way to tell if a group is an embeded group with python
            bindings ? For layers, there is the layerIsEmbeded method of
            the QgsProject class, but what about groups ?<br>
            <br>
          </div>
          Cheers<br>
          <br>
        </div>
        Michael<br>
      </div>
      <div class="gmail_extra"><br>
        <br>
        <div class="gmail_quote">2014-02-19 9:57 GMT+01:00 kimaidou <span
            dir="ltr"><<a moz-do-not-send="true"
              href="mailto:kimaidou@gmail.com" target="_blank">kimaidou@gmail.com</a>></span>:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div dir="ltr">Thanks Adreas for your prompt answer.<br>
              <div class="gmail_extra"><br>
                <div class="gmail_quote">2014-02-19 9:47 GMT+01:00
                  Andreas Neumann <span dir="ltr"><<a
                      moz-do-not-send="true"
                      href="mailto:a.neumann@carto.net" target="_blank">a.neumann@carto.net</a>></span>:
                  <div class="">
                    <br>
                    <blockquote class="gmail_quote" style="margin:0 0 0
                      .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi
                      Michael,<br>
                      <br>
                      It is a known issue and Marco Hugentobler is
                      working on it (hopefully<br>
                      still in time for 2.2).<br>
                    </blockquote>
                    <div><br>
                      <br>
                    </div>
                  </div>
                  <div>Ok. thanks Marco.<br>
                    <br>
                  </div>
                  <div class="">
                    <div> </div>
                    <blockquote class="gmail_quote" style="margin:0 0 0
                      .8ex;border-left:1px #ccc solid;padding-left:1ex">
                      <br>
                      BTW: you will not be able to rearrange the order
                      of individual layers if<br>
                      you embed a whole group - only the group at a
                      whole. </blockquote>
                    <div><br>
                    </div>
                  </div>
                  <div>Exactly. I just tried only because of the issue.
                    I won't need it if groups and layers are embedded
                    correctly.<br>
                  </div>
                  <div class="">
                    <div><br>
                       </div>
                    <blockquote class="gmail_quote" style="margin:0 0 0
                      .8ex;border-left:1px #ccc solid;padding-left:1ex">But
                      the order<br>
                      within the embedded group should be correct once
                      the bug is fixed. If<br>
                      you want to reorder embedded groups or layers you
                      will have to embed<br>
                      them individually several times.<br>
                    </blockquote>
                    <div><br>
                    </div>
                  </div>
                  <div>This is what I did to avoid the bug after I
                    discovered it. I recreated a group and sub groups
                    with individual embeded layers in them. Then I use
                    QGIS project templates to save this state and create
                    new projects with the same group.<br>
                    <br>
                    <br>
                  </div>
                  <div>Michael<br>
                    <br>
                    <br>
                  </div>
                  <div>
                    <div class="h5">
                      <div> </div>
                      <blockquote class="gmail_quote" style="margin:0 0
                        0 .8ex;border-left:1px #ccc
                        solid;padding-left:1ex">
                        <br>
                        Andreas<br>
                        <br>
                        Am 19.02.2014 08:41, schrieb kimaidou:<br>
                        <div>
                          <div>> Hi list,<br>
                            ><br>
                            > Yesterday I played a little bit with
                            the feature "Embed layers or groups".<br>
                            > I works well for single layers, but it
                            seems to behave randomly for groups.<br>
                            > For example, embedding a group
                            containing sub-groups and layers does not<br>
                            > produce the right result in my case :
                            the group is imported, but only<br>
                            > contains the sub-group. All the layers
                            from parent project origninally<br>
                            > contained in the group root are
                            imported in the root of the legend in the<br>
                            > child project. Second problem : the
                            layers are imported with reverse order<br>
                            > compared to their order in the parent
                            project.<br>
                            ><br>
                            > Espected behaviour :<br>
                            ><br>
                            > * imported group<br>
                            > -- * sub-group<br>
                            > ---- * layer A<br>
                            > ---- * layer B<br>
                            > -- * layer 1<br>
                            > -- * layer 2<br>
                            ><br>
                            > Actual "buggy" behaviour :<br>
                            ><br>
                            > * layer 2<br>
                            > * layer 1<br>
                            > * imported group<br>
                            > -- * layer B<br>
                            > -- * layer A<br>
                            ><br>
                            > And I cannot move the layers 1 and 2
                            afterwards in the "imported group" as<br>
                            > the embedded groups are read-only.<br>
                            ><br>
                            > Has anyone seen this happen ?<br>
                            > I would be happy to report a bug in <a
                              moz-do-not-send="true"
                              href="http://hub.qgis.org" target="_blank">hub.qgis.org</a><br>
                            ><br>
                            > Michael<br>
                            ><br>
                            ><br>
                            ><br>
                          </div>
                        </div>
                        >
                        _______________________________________________<br>
                        > Qgis-developer mailing list<br>
                        > <a moz-do-not-send="true"
                          href="mailto:Qgis-developer@lists.osgeo.org"
                          target="_blank">Qgis-developer@lists.osgeo.org</a><br>
                        > <a moz-do-not-send="true"
                          href="http://lists.osgeo.org/mailman/listinfo/qgis-developer"
                          target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br>
                        ><br>
                        <br>
                        _______________________________________________<br>
                        Qgis-developer mailing list<br>
                        <a moz-do-not-send="true"
                          href="mailto:Qgis-developer@lists.osgeo.org"
                          target="_blank">Qgis-developer@lists.osgeo.org</a><br>
                        <a moz-do-not-send="true"
                          href="http://lists.osgeo.org/mailman/listinfo/qgis-developer"
                          target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br>
                      </blockquote>
                    </div>
                  </div>
                </div>
                <br>
              </div>
            </div>
          </blockquote>
        </div>
        <br>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
Qgis-developer mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Qgis-developer@lists.osgeo.org">Qgis-developer@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
    </blockquote>
    <br>
    <br>
    <pre class="moz-signature" cols="72">-- 
Dr. Marco Hugentobler
Sourcepole -  Linux & Open Source Solutions
Weberstrasse 5, CH-8004 Zürich, Switzerland
<a class="moz-txt-link-abbreviated" href="mailto:marco.hugentobler@sourcepole.ch">marco.hugentobler@sourcepole.ch</a> <a class="moz-txt-link-freetext" href="http://www.sourcepole.ch">http://www.sourcepole.ch</a>
Technical Advisor QGIS Project Steering Committee </pre>
  </body>
</html>