diff --git a/.gitattributes b/.gitattributes index d4c0965e9b3..542aa84093e 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1285,6 +1285,8 @@ CGAL_ipelets/doc_tex/CGAL_ipelets/PkgDescription.tex -text CGAL_ipelets/doc_tex/CGAL_ipelets/cgal_ipelets.tex -text CGAL_ipelets/doc_tex/CGAL_ipelets/cgal_ipelets_def.tex -text CGAL_ipelets/doc_tex/CGAL_ipelets/fig/example.png -text +CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipeico.jpg -text +CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipelarge.jpg -text CGAL_ipelets/doc_tex/CGAL_ipelets/main.tex -text CGAL_ipelets/doc_tex/CGAL_ipelets_ref/cgal_ipelets.tex -text CGAL_ipelets/doc_tex/CGAL_ipelets_ref/intro.tex -text diff --git a/CGAL_ipelets/demo/CGAL_ipelets/bbox_restriction.cpp b/CGAL_ipelets/demo/CGAL_ipelets/bbox_restriction.cpp index 34cc13e898e..527a07d890f 100644 --- a/CGAL_ipelets/demo/CGAL_ipelets/bbox_restriction.cpp +++ b/CGAL_ipelets/demo/CGAL_ipelets/bbox_restriction.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2005-2009 INRIA Sophia-Antipolis (France). +// Copyright (c) 2009 INRIA Sophia-Antipolis (France). // All rights reserved. // // This file is part of CGAL (www.cgal.org); you can redistribute it and/or diff --git a/CGAL_ipelets/demo/CGAL_ipelets/generator.cpp b/CGAL_ipelets/demo/CGAL_ipelets/generator.cpp index 8f049c746c8..8896aae8634 100644 --- a/CGAL_ipelets/demo/CGAL_ipelets/generator.cpp +++ b/CGAL_ipelets/demo/CGAL_ipelets/generator.cpp @@ -33,7 +33,6 @@ #include - namespace CGAL_generator{ @@ -67,7 +66,7 @@ void generator::protected_run(int fn) } int nbelements=30; - int size=200; + double size=200; int ret_val; boost::tie(ret_val,nbelements)=request_value_from_user((boost::format("Number of elements (default : %1%)") % nbelements).str() ); @@ -142,7 +141,8 @@ void generator::protected_run(int fn) if (fn==6){ CGAL::Random random; for (std::vector::iterator it_pt=points.begin();it_pt!=points.end();++it_pt) - draw_in_ipe(Circle_2(*it_pt,random.get_double(size/20.,size/2.))); + draw_in_ipe(Circle_2(*it_pt,pow(random.get_double(size/20.,size/2.),2) )); + get_IpePage()->Group(get_IpeletHelper()->CurrentLayer()); } else if (!points.empty())// Draw points diff --git a/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp b/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp index a187767d045..3478c7332bf 100644 --- a/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp +++ b/CGAL_ipelets/demo/CGAL_ipelets/pca.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2005-2009 INRIA Sophia-Antipolis (France). +// Copyright (c) 2009 INRIA Sophia-Antipolis (France). // All rights reserved. // // This file is part of CGAL (www.cgal.org); you can redistribute it and/or diff --git a/CGAL_ipelets/doc_tex/CGAL_ipelets/PkgDescription.tex b/CGAL_ipelets/doc_tex/CGAL_ipelets/PkgDescription.tex index 5e92cf249cb..91788b3887b 100644 --- a/CGAL_ipelets/doc_tex/CGAL_ipelets/PkgDescription.tex +++ b/CGAL_ipelets/doc_tex/CGAL_ipelets/PkgDescription.tex @@ -7,5 +7,5 @@ the Ipe extensible drawing editor.} \ccPkgIntroducedInCGAL{3.5} \ccPkgLicense{\ccLicenseLGPL} -\ccPkgIllustration{Spatial_sorting/fig/hilbert.png}{Spatial_sorting/fig/hilbertLarge.jpg} +\ccPkgIllustration{CGAL_ipelets/fig/ipeico.jpg}{CGAL_ipelets/fig/ipelarge.jpg} \end{ccPkgDescription} diff --git a/CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipeico.jpg b/CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipeico.jpg new file mode 100644 index 00000000000..6389bd4a29b Binary files /dev/null and b/CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipeico.jpg differ diff --git a/CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipelarge.jpg b/CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipelarge.jpg new file mode 100644 index 00000000000..5cfe66029db Binary files /dev/null and b/CGAL_ipelets/doc_tex/CGAL_ipelets/fig/ipelarge.jpg differ diff --git a/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base.h b/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base.h index 48e86def1c1..7dd955c2206 100644 --- a/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base.h +++ b/CGAL_ipelets/include/CGAL/CGAL_Ipelet_base.h @@ -797,6 +797,14 @@ public: } public: + // + // .-----7---------2-------. + // | | + // 3 6 + // | indices | + // 4 1 + // | | + // .-----0---------5-------. template void restrict_circle_to_bbox(const Circle_2& approx_circle, @@ -894,14 +902,16 @@ public: multi_output_iterator it_out) const { if (object->AsGroup()){ + bool deselect_grp=false; for (IpeGroup::const_iterator it=object->AsGroup()->begin(); - it!=object->AsGroup()->end();++it){ - + it!=object->AsGroup()->end();++it) + { IpeObject *obj = (*it)->Clone(); obj->SetMatrix(obj->Matrix()*object->Matrix()); - read_one_active_object(obj,it_out); + bool cur=read_one_active_object(obj,it_out); + deselect_grp=deselect_grp || cur; } - return true; + return deselect_grp; } //detect Points @@ -917,7 +927,7 @@ public: //iterate on each subpath to_deselect=false; for (int i=0;iAsPath()->NumSubPaths();++i){ - if(object->AsPath()-> SubPath(i)->AsSegs()){//do not take elliptic segments + if(object->AsPath()-> SubPath(i)->AsSegs()){ std::list seg_list; bool is_polygon=object-> AsPath() -> SubPath(i)->Closed(); @@ -952,6 +962,8 @@ public: ); it_out++=arc; } + else + to_deselect=true; } } if (object->AsPath() -> SubPath(i)->Closed() &&