28 #include <QtGui/QPixmap>
38 QIcon pf0(
":/nouveau.png");
39 QIcon pf1(
":/charger.png") ;
40 QIcon pf2(
":/ajouter.png") ;
41 QIcon pf3(
":/sauver.png") ;
42 QIcon pf7(
":/file-import-48x48.png") ;
43 QIcon pf4(
":/file-export-48x48.png") ;
44 QIcon pf5(
":/quitter.png") ;
45 QIcon pf6(
":/etage.png") ;
47 QIcon pe1(
":/undo.png") ;
48 QIcon pe2(
":/redo.png") ;
49 QIcon pe3(
":/vider.png") ;
50 QIcon pe4(
":/boutonOptions.png") ;
52 QIcon po1(
":/aide.png") ;
53 QIcon po2(
":/grille.png") ;
55 QIcon pc1(
":/polyligne.png") ;
56 QIcon pc2(
":/polygone.png") ;
57 QIcon pc3(
":/maillage.png") ;
58 QIcon pc4(
":/sphere.png") ;
59 QIcon pc5(
":/cylindre.png") ;
60 QIcon pc6(
":/cone.png") ;
61 QIcon pc7(
":/tore.png") ;
63 QIcon pop1(
":/homothetie.png") ;
64 QIcon pop2(
":/translation.png") ;
65 QIcon pop3(
":/rotation.png") ;
67 QIcon pv1(
":/addvue.png") ;
68 QIcon pv2(
":/deletevue.png") ;
69 QIcon pv3(
":/groupervues.png") ;
70 QIcon pv4(
":/degroupervues.png") ;
74 fichier =
new QMenu(
"&File");
75 fichier_act = addMenu(fichier);
77 fichier -> addAction(pf0 ,
"&New" , FParent ,
78 SLOT(callbackNettoyage()) , Qt::CTRL + Qt::Key_N) ;
80 charger_act = fichier -> addAction(pf1 ,
"&Load" , FParent ,
81 SLOT(callbackLoad()) ,
82 Qt::CTRL + Qt::Key_O) ;
84 ajouter_act = fichier -> addAction(pf2 ,
"&Add" , FParent ,
86 Qt::CTRL + Qt::Key_A) ;
88 sauver_act = fichier -> addAction(pf3 ,
"&Save" , FParent ,
89 SLOT(callbackSave()) ,
90 Qt::CTRL + Qt::Key_S) ;
92 fichier -> addSeparator() ;
94 importer_act = fichier -> addAction(pf7 ,
"&Import" , FParent ,
95 SLOT(callbackImport())) ;
97 exporter_act = fichier -> addAction(pf4 ,
"&Export" , FParent ,
98 SLOT(callbackExport())) ;
100 fichier -> addSeparator() ;
102 fichier -> addAction(
"Search sub-map" , FParent ,
103 SLOT(callbackFindMotif())) ;
105 fichier -> addAction(
"Count all the sub-maps" , FParent ,
106 SLOT(callbackCountMotifs())) ;
108 fichier -> addSeparator() ;
110 fichier -> addAction(pf5 ,
"&Quit" , FParent ,
111 SLOT(callbackQuit()) , Qt::CTRL + Qt::Key_Q) ;
115 edition =
new QMenu(
"&Edition");
116 edition_act = addMenu(edition);
118 edition -> addAction(pe1 ,
"&Undo" , FParent ,
119 SLOT(callbackUndo()) , Qt::Key_U) ;
120 edition -> addAction(pe2 ,
"&Redo" , FParent ,
121 SLOT(callbackRedo()) , Qt::SHIFT + Qt::Key_U) ;
123 edition -> addSeparator() ;
125 edition -> addAction(pe3 ,
"&Empty the stack" , FParent ,
126 SLOT(callbackEmptyUndoRedo()) , Qt::ALT + Qt::Key_U);
128 edition -> addSeparator() ;
130 edition -> addAction(pe4 ,
"&Configuration" , FParent ,
131 SLOT(callbackConfigUndoRedo()) , Qt::CTRL + Qt::Key_U);
135 options =
new QMenu(
"&Options");
136 options_act = addMenu(options);
138 options -> addAction(po1 ,
"Hel&p" , FParent ,
139 SLOT(help()) , Qt::Key_F1) ;
141 options -> addSeparator() ;
143 options -> addAction(
"&Drawing/Plating" , FParent ,
144 SLOT(affich()) , Qt::Key_F2) ;
146 options->addAction(
"&Burst view", FParent,
147 SLOT(view()) , Qt::Key_F3) ;
149 options -> addSeparator() ;
154 options -> addAction(
"Deformation &weighting",
155 FParent, SLOT(pondDef()) , Qt::Key_F4) ;
156 options -> addAction(
"&Extrusion/Thickening" , FParent ,
157 SLOT(extrusion()) , Qt::Key_F5) ;
159 options -> addAction(
"&Interpolation/Smoothing" , FParent ,
160 SLOT(interpol()) , Qt::Key_F6) ;
163 options -> addAction(
"M&ove camera", FParent ,
164 SLOT(affichDivers()) , Qt::Key_F7) ;
166 options -> addSeparator() ;
168 options -> addAction(
"&Colors", FParent ,
169 SLOT(couleurs()) , Qt::Key_F8) ;
171 options -> addSeparator() ;
173 options->addAction(
"&Topological characteristics", FParent,
174 SLOT(caracTopo()), *
new QKeySequence(
"ALT+c"));
176 options->addAction(
"Compute &surfacic homology generators", FParent,
177 SLOT(callbackComputeSurfacicHomology()),
178 *
new QKeySequence(
"ALT+SHIFT+h"));
180 options->addAction(
"Compute volumic &homology generators", FParent,
181 SLOT(callbackComputeVolumicHomology()),
182 *
new QKeySequence(
"ALT+h"));
184 options->addAction(
"Is 2D quasi-&manifold",
186 SLOT(callback2Manifold())) ;
190 creations =
new QMenu(
"C&reate");
191 creations_act = addMenu(creations);
193 creations -> addAction(pc1 ,
"&Dart/Polyline/Face" , FParent ,
194 SLOT(callbackPolyline()) ,
195 *
new QKeySequence(
"CTRL+x,CTRL+1")) ;
196 creations -> addAction(pc2 ,
"Regular &polygon",
198 SLOT(callbackPolygon()) ,
199 *
new QKeySequence(
"CTRL+x,CTRL+2")) ;
200 creations -> addAction(pc3 ,
"&Mesh" , FParent ,
201 SLOT(callbackMeshCreation()) ,
202 *
new QKeySequence(
"CTRL+x,CTRL+3")) ;
203 creations -> addAction(pc4 ,
"&Sphere", FParent ,
204 SLOT(callbackSphere()) ,
205 *
new QKeySequence(
"CTRL+x,CTRL+4")) ;
206 creations -> addAction(pc5 ,
"&Cylinder" , FParent ,
207 SLOT(callbackCylinder()) ,
208 *
new QKeySequence(
"CTRL+x,CTRL+5")) ;
209 creations -> addAction(pc6 ,
"P&yramid/Cone" ,
211 SLOT(callbackPyramide()),
212 *
new QKeySequence(
"CTRL+x,CTRL+6")) ;
213 creations -> addAction(pc7 ,
"&Torus" , FParent ,
214 SLOT(callbackTorus()) ,
215 *
new QKeySequence(
"CTRL+x,CTRL+7")) ;
217 creations -> addSeparator() ;
219 creations -> addAction(
"&Randomize darts" , FParent ,
220 SLOT(callbackRandomizeDarts()));
225 operations_act = addMenu(operations);
228 operations -> addAction(pop2 ,
"&Translation" , FParent ,
229 SLOT(callbackTranslateWindow()) , Qt::Key_T) ;
230 operations -> addAction(pop3 ,
"&Rotation" , FParent ,
231 SLOT(callbackRotateWindow()) , Qt::Key_R) ;
232 operations -> addAction(pop1 ,
"&Homothethy" ,
234 SLOT(callbackScaleWindow()) , Qt::Key_H) ;
235 operations -> addAction(
"M&ove to" , FParent ,
236 SLOT(callbackMovetoWindow()),
237 Qt::SHIFT + Qt::Key_T) ;
239 operations -> addSeparator() ;
242 QMenu * coudre = operations -> addMenu(
"&Sew") ;
244 QMenu * intuitif = coudre -> addMenu(
"&Intuitively") ;
245 intuitif -> addAction(
"&Topologically" , FParent ,
246 SLOT(callbackIntuitiveTopoSew()) ,
247 Qt::SHIFT + Qt::Key_C) ;
248 intuitif -> addAction(
"&Geometrically" , FParent ,
249 SLOT(callbackIntuitiveGeoSew()) , Qt::Key_C) ;
251 coudre -> addSeparator() ;
253 coudre -> addAction(
"&Vertices" , FParent , SLOT(callbackTopoSew0()));
255 QMenu * coudreAretes = coudre -> addMenu(
"&Edges");
256 coudreAretes -> addAction(
"&Topologically" , FParent ,
257 SLOT(callbackTopoSew1())) ;
258 coudreAretes->addAction(
"&Geometrically", FParent ,
259 SLOT(callbackGeoSew1())) ;
261 QMenu * coudreFaces = coudre -> addMenu(
"&Faces") ;
262 coudreFaces -> addAction(
"&Topologically" , FParent ,
263 SLOT(callbackTopoSew2())) ;
264 coudreFaces -> addAction(
"&Geometrically", FParent ,
265 SLOT(callbackGeoSew2())) ;
267 QMenu * coudreVolumes = coudre -> addMenu(
"V&olumes") ;
268 coudreVolumes -> addAction(
"&Topologically" , FParent ,
269 SLOT(callbackTopoSew3())) ;
270 coudreVolumes->addAction(
"&Geometrically", FParent ,
271 SLOT(callbackGeoSew3())) ;
273 coudre -> addSeparator() ;
275 QMenu * coudre1bord = coudre -> addMenu(
"&1-border") ;
276 coudre1bord -> addAction(
"&Topologically" , FParent ,
277 SLOT(callbackTopoSew1borders())) ;
278 coudre1bord->addAction(
"&Geometrically" , FParent ,
279 SLOT(callbackGeoSew1borders())) ;
281 QMenu * coudre2bords = coudre -> addMenu(
"&2-border") ;
282 coudre2bords -> addAction(
"&Topologically" , FParent ,
283 SLOT(callbackTopoSew2borders()),
284 Qt::SHIFT + Qt::Key_B) ;
285 coudre2bords -> addAction(
"&Geometrically", FParent ,
286 SLOT(callbackGeoSew2borders()) , Qt::Key_B) ;
288 coudre -> addSeparator() ;
290 QMenu * inverserCouture =
291 coudre->addMenu(
"&Reverse the last sewing");
292 inverserCouture -> addAction(
"&Orientation" , FParent ,
293 SLOT(callbackInvertLastOperation()) ,
295 inverserCouture -> addAction(
"&Direction" , FParent ,
296 SLOT(callbackInvertLastOperationGeometry()),
297 Qt::SHIFT + Qt::Key_X) ;
300 QMenu * decoudre = operations->addMenu(*
HTML::decode(
"&Unsew"));
302 decoudre -> addAction(
"&Intuitively" , FParent ,
303 SLOT(callbackIntuitiveUnsew()) , Qt::Key_D) ;
305 decoudre -> addSeparator() ;
307 decoudre -> addAction(
"&Vertices" , FParent ,
308 SLOT(callbackUnsew0())) ;
309 decoudre -> addAction(
"&Edges" , FParent ,
310 SLOT(callbackUnsew1())) ;
311 decoudre -> addAction(
"&Faces" , FParent ,
312 SLOT(callbackUnsew2())) ;
313 decoudre -> addAction(
"V&olumes" , FParent ,
314 SLOT(callbackUnsew3())) ;
317 QMenu * placage = operations -> addMenu(
"&Plate") ;
319 placage -> addAction(
"&Intuitively" , FParent ,
320 SLOT(callbackIntuitivePlate()) , Qt::Key_P) ;
322 placage -> addSeparator() ;
324 placage -> addAction(
"&Vertices" , FParent , SLOT(callbackPlate0()));
325 placage -> addAction(
"&Edges" , FParent , SLOT(callbackPlate1()));
326 placage -> addAction(
"&Faces" , FParent , SLOT(callbackPlate2()));
328 placage -> addSeparator() ;
330 placage -> addAction(
"&1-border" , FParent ,
331 SLOT(callbackPlate1borders())) ;
332 placage -> addAction(
"&2-border" , FParent ,
333 SLOT(callbackPlate2borders())) ;
335 operations -> addSeparator() ;
338 QMenu * fusionner = operations -> addMenu(
"&Merge") ;
340 fusionner -> addAction(
"&Intuitively" , FParent ,
341 SLOT(callbackIntuitiveMerge()) , Qt::Key_F) ;
343 fusionner -> addSeparator() ;
345 fusionner -> addAction(
"&Edges", FParent, SLOT(callbackMergeEdges()));
346 fusionner -> addAction(
"&Faces", FParent, SLOT(callbackMergeFaces()));
347 fusionner -> addAction(
"&Volumes", FParent, SLOT(callbackMergeVolumes()));
349 fusionner -> addSeparator() ;
351 fusionner -> addAction(
"&Aligned edges", FParent ,
352 SLOT(callbackMergeColinearEdges())) ;
353 fusionner -> addAction(
"&Coplanar faces" , FParent ,
354 SLOT(callbackMergeCoplanarFaces())) ;
356 fusionner -> addSeparator() ;
358 fusionner -> addAction(
"Faces without &disconnection" , FParent ,
359 SLOT(callbackMergeFacesWithoutDisconnection()));
361 fusionner -> addAction(
"Volumes by keeping balls", FParent ,
362 SLOT(callbackRemoveMarkedFacesButKeepBalls()));
365 fusionner->addAction(
"Shift all edges incident to vertex", FParent ,
366 SLOT(callbackShiftAllEdgesIncidentToVertex()));
367 fusionner->addAction(
"Remove dangling edges", FParent,
368 SLOT(callbackRemoveDanglingEdges()));
370 fusionner -> addAction(
"Simplify 2D object", FParent ,
371 SLOT(callbackSimplify2DObject()));
372 fusionner -> addAction(
"Simplify 3D object", FParent ,
373 SLOT(callbackSimplify3DObject()));
376 QMenu * contracter = operations -> addMenu(
"&Contract") ;
378 contracter -> addAction(
"&Intuitively" , FParent ,
379 SLOT(callbackIntuitiveContract()) ,
380 Qt::SHIFT + Qt::Key_F);
382 contracter -> addSeparator() ;
384 contracter -> addAction(
"&Edges" , FParent ,
385 SLOT(callbackContractEdges())) ;
386 contracter -> addAction(
"&Faces" , FParent ,
387 SLOT(callbackContractFaces())) ;
388 contracter -> addAction(
"&Volumes" , FParent ,
389 SLOT(callbackContractVolumes())) ;
391 contracter -> addSeparator() ;
394 contracter->addAction(
"&Null length edges", FParent ,
395 SLOT(callbackDelNullEdges())) ;
396 contracter -> addAction(
"Flattened f&aces" , FParent ,
397 SLOT(callbackDelFlatFaces())) ;
398 contracter -> addAction(
"Flattened V&olumes" , FParent ,
399 SLOT(callbackDelFlatVolumes())) ;
402 QMenu * inserer = operations -> addMenu(
"&Insert");
404 inserer -> addAction(
"&Vertices" , FParent ,
405 SLOT(callbackInsertVertex())) ;
406 inserer -> addAction(
"&Edges" , FParent ,
407 SLOT(callbackInsertEdge())) ;
408 inserer -> addAction(
"&Faces" , FParent ,
409 SLOT(callbackInsertFace())) ;
412 QMenu * fermer = operations -> addMenu(
"C&lose") ;
414 fermer -> addAction(
"&Intuitively" , FParent ,
415 SLOT(callbackIntuitiveStopUp())) ;
417 fermer -> addSeparator() ;
419 fermer -> addAction(
"&Edges" , FParent , SLOT(callbackStopUp0())) ;
420 fermer -> addAction(
"&Faces" , FParent , SLOT(callbackStopUp1())) ;
421 fermer -> addAction(
"&Volumes" , FParent , SLOT(callbackStopUp2())) ;
422 fermer -> addAction(
"&Connected components" , FParent ,
423 SLOT(callbackStopUp3())) ;
426 QMenu * trianguler = operations -> addMenu(
"Trian&gulate") ;
428 trianguler -> addAction(
"&Depending on selected mode", FParent ,
429 SLOT(callbackContextTriangulate()),
430 Qt::ALT + Qt::Key_T);
432 trianguler -> addSeparator() ;
434 trianguler -> addAction(
"&Edges" , FParent ,
435 SLOT(callbackTriangulateEdges())) ;
436 trianguler -> addAction(
"&Faces" , FParent ,
437 SLOT(callbackTriangulateFaces())) ;
438 trianguler -> addAction(
"&Volumes" , FParent ,
439 SLOT(callbackTriangulateVolumes())) ;
440 trianguler -> addSeparator() ;
442 trianguler -> addAction(
"Triangulate faces &geometrically" ,
443 FParent , SLOT(callbackTriangulateGeoFaces())) ;
445 trianguler -> addAction(
"&Turn selected edge",
446 FParent , SLOT(callbackSwapEdge())) ;
449 QMenu * quadranguler = operations -> addMenu(
"&Quadrangulate") ;
451 QMenu * faces = quadranguler -> addMenu(
"&Faces") ;
452 faces -> addAction(
"&With new vertices" , FParent ,
453 SLOT(callbackQuadrangulateFaces()), Qt::ALT+Qt::Key_Q);
454 faces -> addAction(
"Wi&thout new vertices" , FParent ,
455 SLOT(callbackBasicQuadrangulateFaces())) ;
458 QMenu * calculerDual = operations -> addMenu(
"Compute &dual") ;
459 calculerDual -> addAction(
"&2D" , FParent , SLOT(callbackDual2d())) ;
460 calculerDual -> addAction(
"&3D" , FParent , SLOT(callbackDual3d())) ;
462 operations -> addSeparator() ;
465 QMenu * extruder = operations -> addMenu(
"&Extrude") ;
468 QMenu * normale = extruder -> addMenu(
"Along &normal") ;
469 normale -> addAction(
"&Intuitively" , FParent ,
470 SLOT(callbackIntuitiveExtrudeByNormal()), Qt::Key_N);
472 normale -> addSeparator() ;
474 normale -> addAction(
"&Vertices" , FParent ,
475 SLOT(callbackExtrude0ByNormal())) ;
476 normale -> addAction(
"&Edges" , FParent ,
477 SLOT(callbackExtrude1ByNormal())) ;
478 normale -> addAction(
"&Faces" , FParent ,
479 SLOT(callbackExtrude2ByNormal())) ;
482 QMenu * chemin = extruder -> addMenu(
"Along &path") ;
483 chemin -> addAction(
"&Edges" , FParent ,
484 SLOT(callbackExtrude1ByPath()) , Qt::SHIFT+Qt::Key_E);
485 chemin -> addAction(
"&Faces" , FParent ,
486 SLOT(callbackExtrude2ByPath()) , Qt::Key_E) ;
489 QMenu * axe = extruder -> addMenu(
"Along &axis") ;
491 axe -> addAction(
"&Edges" , FParent ,
492 SLOT(callbackExtrude1ByRevolution()) ,
493 Qt::CTRL + Qt::SHIFT + Qt::Key_E) ;
494 axe -> addAction(
"&Faces" , FParent ,
495 SLOT(callbackExtrude2ByRevolution()) ,
496 Qt::ALT + Qt::SHIFT + Qt::Key_E) ;
499 extruder -> addAction(
"&Thick", FParent, SLOT(callbackThicken())) ;
503 QMenu * interpoler = operations -> addMenu(
"&Interpolate") ;
505 interpoler -> addAction(
"&Edges" , FParent ,
506 SLOT(callbackMeshEdge())) ;
509 QMenu * carres = interpoler -> addMenu(
"&Squares");
510 carres -> addAction(
"0 -> 1" , FParent ,
511 SLOT(callbackMeshSquare01())) ;
512 carres -> addAction(
"0 -> 2" , FParent ,
513 SLOT(callbackMeshSquare02())) ;
514 carres -> addAction(
"1 -> 2" , FParent ,
515 SLOT(callbackMeshSquare12())) ;
517 QMenu * cubes = interpoler -> addMenu(
"C&ubes") ;
518 cubes -> addAction(
"0 -> 1" , FParent ,
519 SLOT(callbackMeshCube01())) ;
520 cubes -> addAction(
"0 -> 2" , FParent ,
521 SLOT(callbackMeshCube02())) ;
522 cubes -> addAction(
"0 -> 3" , FParent ,
523 SLOT(callbackMeshCube03())) ;
524 cubes -> addAction(
"1 -> 2" , FParent ,
525 SLOT(callbackMeshCube12())) ;
526 cubes -> addAction(
"1 -> 3" , FParent ,
527 SLOT(callbackMeshCube13())) ;
528 cubes -> addAction(
"2 -> 3" , FParent ,
529 SLOT(callbackMeshCube23())) ;
532 QMenu * lisser = operations -> addMenu(
"&Smooth") ;
534 lisser -> addAction(
"&Edges" , FParent ,
535 SLOT(callbackSmooth1())) ;
536 lisser -> addAction(
"&Squares" , FParent ,
537 SLOT(callbackSmooth2())) ;
538 lisser -> addAction(
"C&ubes" , FParent ,
539 SLOT(callbackSmooth3())) ;
540 #endif // MODULE_MESH
543 #ifdef MODULE_ROUNDING
544 QMenu * arrondir = operations -> addMenu(
"&Round") ;
546 arrondir -> addAction(
"&Vertices" , FParent ,
547 SLOT(callbackRoundVertices())) ;
548 arrondir -> addAction(
"Edges &2D" , FParent ,
549 SLOT(callbackRoundEdges2d())) ;
550 arrondir -> addAction(
"Edges &3D" , FParent ,
551 SLOT(callbackRoundEdges3d())) ;
553 arrondir -> addSeparator() ;
555 arrondir -> addAction(
"Dug vertices" , FParent ,
556 SLOT(callbackRoundVerticesDig()) , Qt::Key_A) ;
558 arrondir -> addAction(
"3D dug edges" , FParent ,
559 SLOT(callbackRoundEdges3dDig()), Qt::SHIFT+Qt::Key_A);
561 arrondir -> addSeparator() ;
563 arrondir -> addAction(
"2D edges with setback" , FParent ,
564 SLOT(callbackRoundEdges2dWithSetback())) ;
565 arrondir -> addAction(
"3D edges with setback" , FParent ,
566 SLOT(callbackRoundEdges3dWithSetback())) ;
567 arrondir->addAction(
"3D dug edges with setback" , FParent ,
568 SLOT(callbackRoundEdges3dDigWithSetback()) ,
569 Qt::CTRL + Qt::SHIFT + Qt::Key_A) ;
571 arrondir -> addSeparator() ;
573 arrondir -> addAction(
"Variable coefficients" , FParent ,
575 #endif // MODULE_ROUNDING
578 #ifdef MODULE_TRIANGULATION
579 QMenu * triangulation = operations -> addMenu(
"Trian&gulation") ;
581 triangulation -> addAction(
"&Delanyay triangulation" , FParent ,
582 SLOT(callbackDelaunayTriangulation())) ;
584 triangulation -> addSeparator() ;
588 triangulation -> addAction(
"&Mark non-uniform faces" , FParent ,
589 SLOT(callbackMarkNonUniformFaces())) ;
590 triangulation -> addAction(
"&Optimize edges positions" , FParent ,
591 SLOT(callbackOptimizeSelectedEdges())) ;
592 triangulation -> addAction(
"D&elaunay triangulation optimized", FParent ,
593 SLOT(callbackOptimizedDelaunayTriangulation()));
594 #endif // MODULE_TRIANGULATION
597 #ifdef MODULE_COREFINEMENT
598 QMenu * coraffiner = operations -> addMenu(
"Corefine") ;
600 coraffiner -> addAction(
"2D mesh - &sweeping" , FParent ,
601 SLOT(callbackCorefine2dSegmentsSweeping()) ,
602 Qt::Key_AsciiCircum) ;
603 coraffiner -> addAction(
"2D Mesh - &propogation" , FParent ,
604 SLOT(callbackCorefine2dSegmentsPropagation()) ,
608 FParent , SLOT(callbackBooleanOperations2d())) ;
610 coraffiner -> addSeparator() ;
612 coraffiner -> addAction(
"3D Mesh" , FParent ,
613 SLOT(callbackCorefine3dFaces())) ;
614 coraffiner -> addAction(
"3D Faces" , FParent ,
615 SLOT(callbackCorefineMarked3dFaces())) ;
616 coraffiner -> addAction(
"&All selected 3D meshes",FParent ,
617 SLOT(callbackCorefineMarked3dMeshesWith())) ;
618 coraffiner->addAction(
"3D boolean operations 3D" , FParent,
619 SLOT(callbackBooleanOperations3d()), Qt::Key_At);
620 #endif // MODULE_COREFINEMENT
623 #ifdef MODULE_GEOLOGY
624 geologie =
new QMenu(*
HTML::decode(
"&Géologie"));
625 geologie_act = addMenu(geologie);
627 geologie -> addAction(*
HTML::decode(
"&Créer une zone d'incertitude"),
629 SLOT(callbackUncertainZone())) ;
630 geologie -> addAction(*
HTML::decode(
"Créer les &intersections les"
631 " plus proches") , FParent ,
632 SLOT(callbackCreateNearestIntersections())) ;
633 geologie -> addAction(
"&Etendre bords" , FParent ,
634 SLOT(callbackExtendSelectedBorders())) ;
635 geologie -> addAction(*
HTML::decode(
"Etendre &bords jusqu'à une"
636 " surface") , FParent ,
637 SLOT(callbackExtendSelectedBordersToSurface())) ;
639 geologie -> addSeparator() ;
641 geologie -> addAction(*
HTML::decode(
"&Lisser la sélection") ,
643 SLOT(callbackSmoothSelection())) ;
644 geologie -> addAction(*
HTML::decode(
"&Relacher la sélection") ,
646 SLOT(callbackRelaxSelection())) ;
647 geologie -> addAction(
"&Simplifier maillage" , FParent ,
648 SLOT(callbackSimplifyMesh())) ;
649 geologie -> addAction(
"Rece&ntrer" , FParent ,
650 SLOT(callbackCenterSelection())) ;
652 geologie->addAction(*
HTML::decode(
"&Plaquer les sommets de la"
653 " création courante sur les "
654 "faces de la sélection suivante"),
655 FParent , SLOT(callbackPlateVerticesOnFaces())) ;
656 geologie -> addAction(*
HTML::decode(
"Plaquer les sommets de la"
657 " création courante sur les"
658 " &arêtes de la"
659 " sélection suivante"), FParent,
660 SLOT(callbackPlateVerticesOnEdges())) ;
661 geologie->addAction(*
HTML::decode(
"Pla&quer les sommets de la"
662 " création courante sur les somm"
663 "ets de la sélection suivante"),
664 FParent , SLOT(callbackPlateVerticesOnVertices())) ;
666 geologie -> addSeparator() ;
668 geologie -> addAction(*
HTML::decode(
"Sélectionner to&us les"
669 " macros-sommets") , FParent ,
670 SLOT(callbackSelectMacroVertices())) ;
671 geologie -> addAction(*
HTML::decode(
"Sélectionner toutes les"
672 " macros-arê&tes") , FParent ,
673 SLOT(callbackSelectAllMacroEdges())) ;
674 geologie -> addAction(*
HTML::decode(
"Sélectionner les macros-ar"
675 "êtes dési&gnées"),
676 FParent , SLOT(callbackSelectMacroEdges())) ;
677 geologie->addAction(*
HTML::decode(
"Sélectionner les "
678 "macr&os-faces désignées"),
679 FParent , SLOT(callbackSelectMacroFaces())) ;
680 geologie -> addAction(*
HTML::decode(
"Sélectionner les bor&ds entre "
681 "les brins sélectionnés"),
683 SLOT(callbackSelectBordersBetweenSelectedDarts())) ;
685 geologie -> addSeparator() ;
686 geologie -> addAction(
"Simplifier le maillage" , FParent ,
687 SLOT(callbackMeshSimplification())) ;
688 geologie -> addAction(
"Raffiner les trous" , FParent ,
689 SLOT(callbackHolesRefinement())) ;
690 geologie -> addAction(
"Trianguler les trous" , FParent ,
691 SLOT(callbackTriangulateHoles())) ;
692 geologie -> addAction(
"Boucher les trous" , FParent ,
693 SLOT(callbackFillHolesOnMeshes())) ;
695 geologie -> addSeparator() ;
696 geologie -> addAction(*
HTML::decode(
"Déterminer les failles") ,
697 FParent , SLOT(callbackFailleDetection())) ;
698 geologie -> addAction(
"Extraire les failles" , FParent ,
699 SLOT(callbackExtractDetectedFailles())) ;
700 geologie -> addAction(
"Extension des failles" , FParent ,
701 SLOT(callbackExtensionFailleSurface())) ;
703 geologie -> addSeparator() ;
704 geologie -> addAction(
"I&mporter surface GR2D" , FParent ,
705 SLOT(callbackImportGr2d())) ;
706 geologie -> addAction(
"Importer surface &XYZ" , FParent ,
707 SLOT(callbackImportXyz())) ;
708 geologie -> addAction(
"Importer sur&face TS" , FParent ,
709 SLOT(callbackImportTs())) ;
710 geologie -> addAction(
"Importer nuage de poin&ts" , FParent ,
711 SLOT(callbackImportCloud())) ;
712 geologie -> addAction(
"Importer surface VRML" , FParent ,
713 SLOT(callbackImportVrml())) ;
714 geologie -> addAction(
"Exporter surface TS" , FParent ,
715 SLOT(callbackExportTs())) ;
716 #endif // MODULE_GEOLOGY
720 materialiser =
new QMenu(
"&Materialize");
721 materialiser_act = addMenu(materialiser);
723 materialiser -> addAction(
"&Barycenter" , FParent ,
724 SLOT(callbackMaterializeBarycenter())) ;
725 materialiser -> addAction(
"&Axis" , FParent ,
726 SLOT(callbackMaterializeAxe())) ;
727 materialiser -> addAction(
"&Plane" , FParent ,
728 SLOT(callbackMaterializePlane())) ;
729 materialiser -> addAction(
"&Normal vector" , FParent ,
730 SLOT(callbackMaterializeNormalVector())) ;
731 materialiser -> addAction(
"Normal &plane" , FParent ,
732 SLOT(callbackMaterializeOrthoPlane())) ;
734 materialiser -> addSeparator() ;
736 materialiser -> addAction(
"&Reference point" , FParent ,
737 SLOT(callbackMaterializeReferential())) ;
741 selection =
new QMenu(
"&Selection");
742 selection_act = addMenu(selection);
744 selection -> addAction(
"Reinit" , FParent ,
745 SLOT(callbackReinitSelection()) ,
747 selection -> addAction(
"Inverse" , FParent ,
748 SLOT(callbackNegateSelection()) ,
750 selection -> addAction(
"Swap" , FParent ,
751 SLOT(callbackSwapSelections()) ,
754 selection -> addSeparator() ;
756 selection -> addAction(
"Duplicate" , FParent ,
757 SLOT(callbackDuplicateSelection()) ,
760 selection -> addAction(
"Remove" , FParent ,
761 SLOT(callbackDeleteSelection()) ,
764 selection -> addSeparator() ;
766 QMenu * etendre = selection -> addMenu(
"Grow") ;
767 QMenu * etendre1pas = etendre -> addMenu(
"1 step") ;
769 etendre1pas -> addAction(
"Forward" , FParent ,
770 SLOT(callbackGoForward1()) ,
772 etendre1pas -> addAction(*
HTML::decode(
"Backward") , FParent ,
773 SLOT(callbackGoBackward1()) ,
775 etendre1pas -> addAction(
"To the left" , FParent ,
776 SLOT(callbackGoLeft1()) ,
778 etendre1pas -> addAction(
"To the right" , FParent ,
779 SLOT(callbackGoRight1()) ,
782 QMenu * etendreRepet = etendre->addMenu(
"Repetitively");
784 etendreRepet -> addAction(
"Forward" , FParent ,
785 SLOT(callbackGoForward1Rep()) ,
786 Qt::CTRL + Qt::Key_I) ;
787 etendreRepet -> addAction(
"Backward" , FParent ,
788 SLOT(callbackGoBackward1Rep()) ,
789 Qt::CTRL + Qt::Key_K) ;
790 etendreRepet -> addAction(
"To the left" , FParent ,
791 SLOT(callbackGoLeft1Rep()) ,
792 Qt::CTRL + Qt::Key_J) ;
793 etendreRepet -> addAction(
"To the right" , FParent ,
794 SLOT(callbackGoRight1Rep()) ,
795 Qt::CTRL + Qt::Key_L) ;
797 QMenu * reduire = selection->addMenu(
"Reduce");
798 QMenu * reduire1pas = reduire -> addMenu(
"1 step") ;
800 reduire1pas -> addAction(
"Forward" , FParent ,
801 SLOT(callbackGoForward0()) ,
802 Qt::SHIFT + Qt::Key_I) ;
803 reduire1pas -> addAction(
"Backward" , FParent ,
804 SLOT(callbackGoBackward0()) ,
805 Qt::SHIFT + Qt::Key_K) ;
806 reduire1pas -> addAction(
"To the left" , FParent ,
807 SLOT(callbackGoLeft0()) ,
808 Qt::SHIFT + Qt::Key_J) ;
809 reduire1pas -> addAction(
"To the right" , FParent ,
810 SLOT(callbackGoRight0()) ,
811 Qt::SHIFT + Qt::Key_L) ;
813 QMenu * reduireRepet =
814 reduire->addMenu(
"Repetitively") ;
816 reduireRepet -> addAction(
"Forward" , FParent ,
817 SLOT(callbackGoForward0Rep()) ,
818 Qt::CTRL + Qt::SHIFT + Qt::Key_I) ;
819 reduireRepet -> addAction(
"Backward" , FParent ,
820 SLOT(callbackGoBackward0Rep()) ,
821 Qt::CTRL + Qt::SHIFT + Qt::Key_K) ;
822 reduireRepet -> addAction(
"To the left" , FParent ,
823 SLOT(callbackGoLeft0Rep()) ,
824 Qt::CTRL + Qt::SHIFT + Qt::Key_J) ;
825 reduireRepet -> addAction(
"To the right" , FParent ,
826 SLOT(callbackGoRight0Rep()) ,
827 Qt::CTRL + Qt::SHIFT + Qt::Key_L) ;
829 selection -> addSeparator() ;
831 QMenu * marquerInterieur =
834 marquerInterieur -> addAction(
"2D" , FParent ,
835 SLOT(callbackMarkInterior2())) ;
836 marquerInterieur -> addAction(
"3D" , FParent ,
837 SLOT(callbackMarkInterior3())) ;
839 selection -> addSeparator() ;
841 QMenu * selectBords = selection->addMenu(
"Select borders") ;
843 selectBords -> addAction(
"Intuitively" , FParent ,
844 SLOT(callbackIntuitiveSelectBorders()) ,
845 Qt::ALT + Qt::Key_B) ;
847 selectBords -> addSeparator() ;
849 selectBords -> addAction(
"0-border" , FParent ,
850 SLOT(callbackSelect0borders())) ;
851 selectBords -> addAction(
"1-border" , FParent ,
852 SLOT(callbackSelect1borders())) ;
853 selectBords -> addAction(
"2-border" , FParent ,
854 SLOT(callbackSelect2borders())) ;
855 selectBords -> addAction(
"3-border" , FParent ,
856 SLOT(callbackSelect3borders())) ;
858 selection->addAction(
"Select non planar faces", FParent ,
859 SLOT(callbackSelectNonPlanarFaces()));
861 selection -> addSeparator();
863 selection -> addAction(
"Incident cells" , FParent ,
864 SLOT(callbackSelectIncidents()) ,
867 QMenu * avancer = selection -> addMenu(
"Move by") ;
869 avancer -> addAction(
"Alpha0" , FParent ,
870 SLOT(callbackGoAlpha0()), Qt::ALT + Qt::Key_0) ;
871 avancer -> addAction(
"Alpha1" , FParent ,
872 SLOT(callbackGoAlpha1()), Qt::ALT + Qt::Key_1) ;
873 avancer -> addAction(
"Alpha2" , FParent ,
874 SLOT(callbackGoAlpha2()), Qt::ALT + Qt::Key_2) ;
875 avancer -> addAction(
"Alpha3" , FParent ,
876 SLOT(callbackGoAlpha3()), Qt::ALT + Qt::Key_3) ;
880 vues =
new QMenu(
"&Views");
881 vues_act = addMenu(vues);
883 QMenu * arranger = vues -> addMenu(
"&Organize") ;
884 arranger -> addAction(
"&Cascade" , FParent ,
886 arranger -> addAction(
"&Mosaic" , FParent ,
887 SLOT(tile()) , Qt::Key_M) ;
889 vues -> addAction(pv2 ,
"&Remove" , FParent ,
890 SLOT(deleteView()) , Qt::Key_Backspace) ;
892 QMenu * basculer = vues -> addMenu(
"&Swith to") ;
893 basculer -> addAction(
"&3D view" , FParent ,
894 SLOT(basculeView3D()) , Qt::Key_0);
895 basculer -> addAction(
"&XY view" , FParent ,
896 SLOT(basculeViewXY()) , Qt::Key_1);
897 basculer -> addAction(
"&YZ view" , FParent ,
898 SLOT(basculeViewYZ()) , Qt::Key_2);
899 basculer -> addAction(
"&ZX view" , FParent ,
900 SLOT(basculeViewZX()) , Qt::Key_3);
901 basculer -> addSeparator() ;
902 basculer -> addAction(
"&Multi-view" , FParent ,
903 SLOT(basculeViewMulti()) , Qt::Key_4);
905 vues -> addSeparator() ;
907 QMenu * ajouter = vues -> addMenu(
"&Add") ;
908 ajouter -> addAction(pv1 ,
"&3D view" , FParent ,
909 SLOT(addView3D()) , Qt::CTRL + Qt::Key_0);
910 ajouter -> addAction(
"&XY view" , FParent ,
911 SLOT(addViewXY()) , Qt::CTRL + Qt::Key_1) ;
912 ajouter -> addAction(
"&YZ view" , FParent ,
913 SLOT(addViewYZ()) , Qt::CTRL + Qt::Key_2) ;
914 ajouter -> addAction(
"&ZX view" , FParent ,
915 SLOT(addViewZX()) , Qt::CTRL + Qt::Key_3) ;
916 ajouter -> addSeparator() ;
917 ajouter -> addAction(
"&Multi-view" , FParent ,
918 SLOT(addViewMulti()) , Qt::CTRL + Qt::Key_4) ;
920 vues -> addSeparator() ;
922 QMenu * grouper = vues -> addMenu(
"&Group") ;
923 grouper -> addAction(pv3 ,
"&All the views with the current view" ,
924 FParent , SLOT(OperationGroupAllGeneral()) ,
927 grouper -> addSeparator() ;
929 grouper -> addAction(
"&Precompiles of all the views", FParent ,
930 SLOT(OperationGroupAllPrecomp())) ;
932 grouper -> addAction(
"Camera position of all the views" ,
933 FParent , SLOT(OperationGroupAllEyePos())) ;
935 grouper -> addAction(
"Aimed point of all the views" ,
936 FParent , SLOT(OperationGroupAllAimedPos())) ;
938 grouper -> addAction(
"Drawing parameters of all the views" ,
939 FParent , SLOT(OperationGroupAllDrawing())) ;
941 grouper -> addSeparator() ;
943 grouper->addAction(
"Current view and double-clicked view",
944 FParent , SLOT(OperationGroupGeneral()) ,
945 Qt::ALT + Qt::Key_G) ;
947 grouper -> addSeparator() ;
949 grouper->addAction(
"&Precompiles of these 2 views",
950 FParent, SLOT(OperationGroupPrecomp()));
952 grouper -> addAction(
"Camera position of these 2 views" ,
953 FParent , SLOT(OperationGroupEyePos()));
955 grouper->addAction(
"Aimed point of these 2 views",
956 FParent, SLOT(OperationGroupAimedPos()));
958 grouper->addAction(
"Drawing parameters of these 2 views" ,
959 FParent , SLOT(OperationGroupDrawing()));
961 QMenu * degrouper = vues->addMenu(
"&Ungroup");
963 degrouper -> addAction(pv4 ,
"&All the views" , FParent ,
964 SLOT(OperationUngroupAllGeneral()) ,
965 Qt::SHIFT + Qt::Key_G) ;
967 degrouper -> addSeparator() ;
969 degrouper->addAction(
"&Precompiles of all the views", FParent ,
970 SLOT(OperationUngroupAllPrecompiles()));
972 degrouper -> addAction(
"Camera position of all the views" ,
973 FParent , SLOT(OperationUngroupAllEyePos()));
975 degrouper -> addAction(
"Aimed point of all the views", FParent ,
976 SLOT(OperationUngroupAllAimedPos()));
978 degrouper->addAction(
"Drawing parameters of all the views", FParent ,
979 SLOT(OperationUngroupAllDrawing()));
981 degrouper -> addSeparator() ;
983 degrouper -> addAction(
"Curent view from others" ,
984 FParent , SLOT(OperationUngroupGeneral()) ,
985 *
new QKeySequence(
"SHIFT+ALT+Key_G")) ;
987 degrouper -> addSeparator() ;
989 degrouper->addAction(
"Precompiles of this view" ,
990 FParent, SLOT(OperationUngroupPrecompiles()));
992 degrouper -> addAction(
"Camera position of this view" ,
993 FParent , SLOT(OperationUngroupEyePos()));
995 degrouper->addAction(
"Aimed point of this view" ,
996 FParent, SLOT(OperationUngroupAimedPos()));
998 degrouper->addAction(
"Drawing parameters of this view", FParent ,
999 SLOT(OperationUngroupDrawing()));
1001 QMenu * pointDeMire = vues->addMenu(
"&Aimed point") ;
1003 pointDeMire -> addAction(
"&Origin" , FParent ,
1004 SLOT(mireOrigine()) , Qt::Key_O) ;
1005 pointDeMire->addAction(
"&Vertex incident to 'last'",
1006 FParent, SLOT(mireSommet()), Qt::Key_Exclam);
1008 pointDeMire -> addSeparator();
1010 QMenu* centre = pointDeMire ->addMenu(
"&Center of the bounding box of");
1012 centre -> addAction(
"&Face incident to 'last'",
1013 FParent , SLOT(mireFace())) ;
1014 centre -> addAction(
"&Volume incident to 'last'" , FParent ,
1015 SLOT(mireVolume())) ;
1016 centre->addAction(
"&Connected component incident to 'last'", FParent ,
1017 SLOT(mireCompConnexe())) ;
1018 centre -> addSeparator() ;
1019 centre -> addAction(
"All the &marked darts" , FParent ,
1020 SLOT(mireBrinsMarques()) , Qt::SHIFT + Qt::Key_O) ;
1021 centre -> addAction(
"&All the darts" , FParent ,
1022 SLOT(mireBrins()) , Qt::CTRL + Qt::SHIFT + Qt::Key_O) ;
1025 #ifdef MODULE_SPAMOD
1026 QMenu * visualisation = vues -> addMenu(
"&Spamod mode") ;
1028 visualisation -> addAction(
"&Burst view" , FParent,
1029 SLOT(callbackBackToBurstView())) ;
1030 visualisation -> addSeparator() ;
1031 visualisation -> addAction(
"&Topological view" , FParent ,
1032 SLOT(callbackTopologicalView())) ;
1033 visualisation -> addAction(
"&Euclidean view" , FParent ,
1034 SLOT(callbackEuclidianView())) ;
1035 visualisation -> addAction(
"&Analytic view" , FParent ,
1036 SLOT(callbackAnalyticView())) ;
1037 visualisation -> addAction(
"&Voxels view" , FParent ,
1038 SLOT(callbackVoxelView())) ;
1039 visualisation -> addAction(
"&K2 view" , FParent ,
1040 SLOT(callbackK2View())) ;
1041 visualisation -> addSeparator() ;
1042 visualisation -> addAction(
"&Switch to the next view" , FParent ,
1043 SLOT(callbackSpamodSwitchToNextView())) ;
1044 #endif // MODULE_SPAMOD