Commit e832a6b8 authored by charras's avatar charras

pcbnew: fixed: footprint flip and rotate with hotkeys not undoable.

parent ce66aaa2
...@@ -108,7 +108,7 @@ void WinEDA_SchematicFrame::OnSetOptions( wxCommandEvent& event ) ...@@ -108,7 +108,7 @@ void WinEDA_SchematicFrame::OnSetOptions( wxCommandEvent& event )
DIALOG_EESCHEMA_OPTIONS dlg( this ); DIALOG_EESCHEMA_OPTIONS dlg( this );
wxLogDebug( _( "Current grid array index %d." ), wxLogDebug( wxT( "Current grid array index %d." ),
grid_list.Index( GetBaseScreen()->GetGrid() ) ); grid_list.Index( GetBaseScreen()->GetGrid() ) );
units.Add( GetUnitsLabel( INCHES ) ); units.Add( GetUnitsLabel( INCHES ) );
units.Add( GetUnitsLabel( MILLIMETRE ) ); units.Add( GetUnitsLabel( MILLIMETRE ) );
......
No preview for this file type
...@@ -2,8 +2,8 @@ msgid "" ...@@ -2,8 +2,8 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: kicad\n" "Project-Id-Version: kicad\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2009-11-28 14:17+0100\n" "POT-Creation-Date: 2009-12-02 10:24+0100\n"
"PO-Revision-Date: 2009-11-28 14:21+0100\n" "PO-Revision-Date: 2009-12-02 10:25+0100\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: kicad team <jean-pierre.charras@ujf-grenoble.fr>\n" "Language-Team: kicad team <jean-pierre.charras@ujf-grenoble.fr>\n"
"MIME-Version: 1.0\n" "MIME-Version: 1.0\n"
...@@ -2720,7 +2720,7 @@ msgstr "Simple Face" ...@@ -2720,7 +2720,7 @@ msgstr "Simple Face"
#: pcbnew/dialog_layers_setup.cpp:119 #: pcbnew/dialog_layers_setup.cpp:119
msgid "Single Side, SMD on Back" msgid "Single Side, SMD on Back"
msgstr "" msgstr "Simple face, CMS coté Cuivre"
#: pcbnew/dialog_layers_setup.cpp:120 #: pcbnew/dialog_layers_setup.cpp:120
msgid "Two Layers, Parts on Front" msgid "Two Layers, Parts on Front"
...@@ -6350,12 +6350,59 @@ msgstr "Ajout Composant" ...@@ -6350,12 +6350,59 @@ msgstr "Ajout Composant"
msgid "Add Power" msgid "Add Power"
msgstr "Ajouter Alims" msgstr "Ajouter Alims"
#: eeschema/pinedit.cpp:194
msgid "This position is already occupied by another pin. Continue?"
msgstr "Position occupée par une autre pin. Continuer ?"
#: eeschema/pinedit.cpp:302
#: eeschema/pinedit.cpp:420
#, c-format
msgid "Initial pin position (%d, %d)"
msgstr "Position initiane de la pin (%d, %d)"
#: eeschema/pinedit.cpp:626
msgid "No pins!"
msgstr "Pas de Pins!"
#: eeschema/pinedit.cpp:637
msgid "Marker Information"
msgstr "Info Marqueur"
#: eeschema/pinedit.cpp:656
#, c-format
msgid "<b>Duplicate pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b> conflicts with pin %s \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin dupliquée %s</b> \"%s\" en position <b>(%.3f, %.3f)</b> en conflit avec pin %s \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:669
#: eeschema/pinedit.cpp:708
#, c-format
msgid " in part %c"
msgstr " en composant %c"
#: eeschema/pinedit.cpp:676
#: eeschema/pinedit.cpp:715
msgid " of converted"
msgstr " de converti"
#: eeschema/pinedit.cpp:678
#: eeschema/pinedit.cpp:717
msgid " of normal"
msgstr " de normal"
#: eeschema/pinedit.cpp:699
#, c-format
msgid "<b>Off grid pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin %s hors grille </b> \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:726
msgid "No off grid or duplicate pins were found."
msgstr "Pas de pins doublées ou hors grille trouvées"
#: eeschema/libedit.cpp:25 #: eeschema/libedit.cpp:25
msgid "Component Library Editor: " msgid "Component Library Editor: "
msgstr "Editeur de Composants" msgstr "Editeur de Composants"
#: eeschema/libedit.cpp:30 #: eeschema/libedit.cpp:30
#: eeschema/viewlibs.cpp:115
msgid "no library selected" msgid "no library selected"
msgstr "Pas de librairie sélectionnée" msgstr "Pas de librairie sélectionnée"
...@@ -6412,12 +6459,10 @@ msgid "Document file \"" ...@@ -6412,12 +6459,10 @@ msgid "Document file \""
msgstr "Fichier de doc \"" msgstr "Fichier de doc \""
#: eeschema/libedit.cpp:303 #: eeschema/libedit.cpp:303
#: eeschema/viewlibs.cpp:314
msgid "Part" msgid "Part"
msgstr "Part" msgstr "Part"
#: eeschema/libedit.cpp:315 #: eeschema/libedit.cpp:315
#: eeschema/viewlibs.cpp:315
msgid "Alias" msgid "Alias"
msgstr "Alias" msgstr "Alias"
...@@ -6442,12 +6487,10 @@ msgid "Component" ...@@ -6442,12 +6487,10 @@ msgid "Component"
msgstr "Composant" msgstr "Composant"
#: eeschema/libedit.cpp:341 #: eeschema/libedit.cpp:341
#: eeschema/viewlibs.cpp:316
msgid "Description" msgid "Description"
msgstr "Description" msgstr "Description"
#: eeschema/libedit.cpp:348 #: eeschema/libedit.cpp:348
#: eeschema/viewlibs.cpp:317
msgid "Key words" msgid "Key words"
msgstr "Mots clé" msgstr "Mots clé"
...@@ -6501,33 +6544,57 @@ msgstr "" ...@@ -6501,33 +6544,57 @@ msgstr ""
"\n" "\n"
"Supprimer le composant courant de l'écran?" "Supprimer le composant courant de l'écran?"
#: eeschema/libedit.cpp:509 #: eeschema/libedit.cpp:511
msgid "This new component has no name and cannot be created. Aborted" msgid "This new component has no name and cannot be created. Aborted"
msgstr "Ce noveau composant n'a pas de nom et ne peut être créé, Abandon" msgstr "Ce noveau composant n'a pas de nom et ne peut être créé, Abandon"
#: eeschema/libedit.cpp:520 #: eeschema/libedit.cpp:522
#, c-format #, c-format
msgid "Component \"%s\" already exists in library \"%s\"." msgid "Component \"%s\" already exists in library \"%s\"."
msgstr "Composant \"%s\" déjà existant en librairie \"%s\"." msgstr "Composant \"%s\" déjà existant en librairie \"%s\"."
#: eeschema/libedit.cpp:585 #: eeschema/libedit.cpp:587
msgid "No component to save." msgid "No component to save."
msgstr "Pas de composant à sauver." msgstr "Pas de composant à sauver."
#: eeschema/libedit.cpp:594 #: eeschema/libedit.cpp:596
msgid "No library specified." msgid "No library specified."
msgstr "Pas de librairie spécifiée." msgstr "Pas de librairie spécifiée."
#: eeschema/libedit.cpp:604 #: eeschema/libedit.cpp:606
#, c-format #, c-format
msgid "Component \"%s\" exists. Change it?" msgid "Component \"%s\" exists. Change it?"
msgstr "Le composant \" %s\" existe, Le changer ?" msgstr "Le composant \" %s\" existe, Le changer ?"
#: eeschema/libedit.cpp:622 #: eeschema/libedit.cpp:624
#, c-format #, c-format
msgid "Component %s saved in library %s" msgid "Component %s saved in library %s"
msgstr "Composant %s sauvé en librairie %s" msgstr "Composant %s sauvé en librairie %s"
#: eeschema/schframe.cpp:364
msgid "Schematic modified, Save before exit ?"
msgstr "Schématique modifiée, Sauver avant de quitter ?"
#: eeschema/schframe.cpp:503
msgid "Draw wires and busses in any direction"
msgstr "Tracer les fils et bus de n'importe quelle direction"
#: eeschema/schframe.cpp:504
msgid "Draw horizontal and vertical wires and busses only"
msgstr "Autoriser fils et bus verticaux et horizontaux seulement"
#: eeschema/schframe.cpp:514
msgid "Do not show hidden pins"
msgstr "Ne pas affichager les pins invisibles"
#: eeschema/schframe.cpp:515
msgid "Show hidden pins"
msgstr "Force affichage des pins invisibles"
#: eeschema/schframe.cpp:618
msgid "Schematic"
msgstr "Schématique"
#: eeschema/netlist.cpp:88 #: eeschema/netlist.cpp:88
msgid "List" msgid "List"
msgstr "Liste" msgstr "Liste"
...@@ -6640,30 +6707,6 @@ msgstr "Impossible de créer le fichier " ...@@ -6640,30 +6707,6 @@ msgstr "Impossible de créer le fichier "
msgid "Library Browser" msgid "Library Browser"
msgstr "Visualisateur de Librairies" msgstr "Visualisateur de Librairies"
#: eeschema/schframe.cpp:364
msgid "Schematic modified, Save before exit ?"
msgstr "Schématique modifiée, Sauver avant de quitter ?"
#: eeschema/schframe.cpp:503
msgid "Draw wires and busses in any direction"
msgstr "Tracer les fils et bus de n'importe quelle direction"
#: eeschema/schframe.cpp:504
msgid "Draw horizontal and vertical wires and busses only"
msgstr "Autoriser fils et bus verticaux et horizontaux seulement"
#: eeschema/schframe.cpp:514
msgid "Do not show hidden pins"
msgstr "Ne pas affichager les pins invisibles"
#: eeschema/schframe.cpp:515
msgid "Show hidden pins"
msgstr "Force affichage des pins invisibles"
#: eeschema/schframe.cpp:618
msgid "Schematic"
msgstr "Schématique"
#: eeschema/eeredraw.cpp:95 #: eeschema/eeredraw.cpp:95
msgid "Sheet" msgid "Sheet"
msgstr "Feuille" msgstr "Feuille"
...@@ -7062,6 +7105,10 @@ msgstr "Noir" ...@@ -7062,6 +7105,10 @@ msgstr "Noir"
msgid "Background Color:" msgid "Background Color:"
msgstr "Couleur du Fond:" msgstr "Couleur du Fond:"
#: eeschema/eeschema_config.cpp:326
msgid "Save Project Settings"
msgstr "Sauver Optionsr Projet"
#: eeschema/erc.cpp:210 #: eeschema/erc.cpp:210
msgid "Duplicate Sheet name" msgid "Duplicate Sheet name"
msgstr "Nom de feuille en double" msgstr "Nom de feuille en double"
...@@ -7917,12 +7964,10 @@ msgid "Check if you want this field's text rotated 90 degrees" ...@@ -7917,12 +7964,10 @@ msgid "Check if you want this field's text rotated 90 degrees"
msgstr "Activer si vous voulez avoir le texte de ce champ tourné à 90°" msgstr "Activer si vous voulez avoir le texte de ce champ tourné à 90°"
#: eeschema/dialog_edit_component_in_schematic_fbp.cpp:136 #: eeschema/dialog_edit_component_in_schematic_fbp.cpp:136
#: eeschema/dialog_edit_label_base.cpp:43
msgid "Bold" msgid "Bold"
msgstr "Gras" msgstr "Gras"
#: eeschema/dialog_edit_component_in_schematic_fbp.cpp:136 #: eeschema/dialog_edit_component_in_schematic_fbp.cpp:136
#: eeschema/dialog_edit_label_base.cpp:43
msgid "Bold Italic" msgid "Bold Italic"
msgstr "Gras Italique" msgstr "Gras Italique"
...@@ -8090,54 +8135,6 @@ msgstr "Champ 8" ...@@ -8090,54 +8135,6 @@ msgstr "Champ 8"
msgid "All existing users fields" msgid "All existing users fields"
msgstr "Tous les champs existants" msgstr "Tous les champs existants"
#: eeschema/pinedit.cpp:184
msgid "This position is already occupied by another pin. Continue?"
msgstr "Position occupée par une autre pin. Continuer ?"
#: eeschema/pinedit.cpp:292
#: eeschema/pinedit.cpp:410
#, c-format
msgid "Initial pin position (%d, %d)"
msgstr "Position initiane de la pin (%d, %d)"
#: eeschema/pinedit.cpp:616
msgid "No pins!"
msgstr "Pas de Pins!"
#: eeschema/pinedit.cpp:627
msgid "Marker Information"
msgstr "Info Marqueur"
#: eeschema/pinedit.cpp:646
#, c-format
msgid "<b>Duplicate pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b> conflicts with pin %s \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin dupliquée %s</b> \"%s\" en position <b>(%.3f, %.3f)</b> en conflit avec pin %s \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:659
#: eeschema/pinedit.cpp:698
#, c-format
msgid " in part %c"
msgstr " en composant %c"
#: eeschema/pinedit.cpp:666
#: eeschema/pinedit.cpp:705
msgid " of converted"
msgstr " de converti"
#: eeschema/pinedit.cpp:668
#: eeschema/pinedit.cpp:707
msgid " of normal"
msgstr " de normal"
#: eeschema/pinedit.cpp:689
#, c-format
msgid "<b>Off grid pin %s</b> \"%s\" at location <b>(%.3f, %.3f)</b>"
msgstr "<b>Pin %s hors grille </b> \"%s\" en position <b>(%.3f, %.3f)</b>"
#: eeschema/pinedit.cpp:716
msgid "No off grid or duplicate pins were found."
msgstr "Pas de pins doublées ou hors grille trouvées"
#: eeschema/tool_sch.cpp:37 #: eeschema/tool_sch.cpp:37
msgid "Open schematic project" msgid "Open schematic project"
msgstr "Ouvrir un Projet schématique" msgstr "Ouvrir un Projet schématique"
...@@ -8320,6 +8317,50 @@ msgstr "" ...@@ -8320,6 +8317,50 @@ msgstr ""
msgid "File <%s> not found." msgid "File <%s> not found."
msgstr "Fichier <%s> non trouvé" msgstr "Fichier <%s> non trouvé"
#: eeschema/dialog_annotate_base.cpp:22
msgid "Scope"
msgstr "Sélection"
#: eeschema/dialog_annotate_base.cpp:31
msgid "Use the &entire schematic"
msgstr "Utiliser la schématique &entière"
#: eeschema/dialog_annotate_base.cpp:34
msgid "Use the current &page only"
msgstr "Utiliser la &feuille active uniquement"
#: eeschema/dialog_annotate_base.cpp:40
msgid "&Keep existing annotation"
msgstr "&Garder l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:43
msgid "&Reset existing annotation"
msgstr "&Supprimer l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:51
msgid "Annotation Order"
msgstr "Sens de Annotation"
#: eeschema/dialog_annotate_base.cpp:63
msgid "Sort Components by &X Position"
msgstr "Trier les Composants par Position &X"
#: eeschema/dialog_annotate_base.cpp:77
msgid "Sort Components by &Y Position"
msgstr "Trier les Composants par Position &Y"
#: eeschema/dialog_annotate_base.cpp:91
msgid "Sort Components by &Value"
msgstr "Trier Composants par &Valeur"
#: eeschema/dialog_annotate_base.cpp:113
msgid "Clear Annotation"
msgstr "Suppression Annotation"
#: eeschema/dialog_annotate_base.cpp:116
msgid "Annotation"
msgstr "Annotation"
#: eeschema/build_BOM.cpp:51 #: eeschema/build_BOM.cpp:51
msgid "Bill of Materials file (*.lst)|*.lst" msgid "Bill of Materials file (*.lst)|*.lst"
msgstr "Fichier Liste du Materiel (*.lst)|*.lst" msgstr "Fichier Liste du Materiel (*.lst)|*.lst"
...@@ -9169,10 +9210,6 @@ msgstr "Les librairies suivantes n'ont pas pu être trouvées:" ...@@ -9169,10 +9210,6 @@ msgstr "Les librairies suivantes n'ont pas pu être trouvées:"
msgid "text only had %d parameters of the required 8" msgid "text only had %d parameters of the required 8"
msgstr "le texte a seulement %d paramètres sur les 8 requis" msgstr "le texte a seulement %d paramètres sur les 8 requis"
#: eeschema/eeschema_config.cpp:284
msgid "Save Project Settings"
msgstr "Sauver Optionsr Projet"
#: eeschema/class_drc_erc_item.cpp:39 #: eeschema/class_drc_erc_item.cpp:39
msgid "ERC err unspecified" msgid "ERC err unspecified"
msgstr "Erreur ERC non specifiée" msgstr "Erreur ERC non specifiée"
...@@ -9410,84 +9447,6 @@ msgstr "" ...@@ -9410,84 +9447,6 @@ msgstr ""
"Les noms d'empreintes peuvent utiliser des caractères jockers.\n" "Les noms d'empreintes peuvent utiliser des caractères jockers.\n"
"(Comme sm* pour autoriser tous les noms d'empreintes commençant par sm)." "(Comme sm* pour autoriser tous les noms d'empreintes commençant par sm)."
#: eeschema/dialog_options.cpp:139
#: eeschema/dialog_options.cpp:286
msgid "Delta Step X"
msgstr "Incrément X"
#: eeschema/dialog_options.cpp:144
#: eeschema/dialog_options.cpp:292
msgid "Delta Step Y"
msgstr "Incrément Y"
#: eeschema/dialog_options.cpp:213
msgid "Draw Options:"
msgstr "Options de Tracé:"
#: eeschema/dialog_options.cpp:222
msgid "Normal (50 mils)"
msgstr "Normal (50 mils)"
#: eeschema/dialog_options.cpp:223
msgid "Small (25 mils)"
msgstr "Petit (25 mils)"
#: eeschema/dialog_options.cpp:224
msgid "Very small (10 mils)"
msgstr "Très petit (10 mils)"
#: eeschema/dialog_options.cpp:225
msgid "Special (5 mils)"
msgstr "Spécial (5 mils)"
#: eeschema/dialog_options.cpp:226
msgid "Special (2 mils)"
msgstr "Spécial (2 mils)"
#: eeschema/dialog_options.cpp:227
msgid "Special (1 mil)"
msgstr "Spécial (1 mil)"
#: eeschema/dialog_options.cpp:228
msgid "Grid Size"
msgstr "Dim Grille"
#: eeschema/dialog_options.cpp:234
msgid "Show alls"
msgstr "Tout Afficher"
#: eeschema/dialog_options.cpp:235
msgid "Show pins"
msgstr "Montrer Pins"
#: eeschema/dialog_options.cpp:247
msgid "millimeter"
msgstr "millimètre"
#: eeschema/dialog_options.cpp:248
msgid "inches"
msgstr "Pouces"
#: eeschema/dialog_options.cpp:257
msgid "Horiz/Vertical"
msgstr "Horiz/Vertical"
#: eeschema/dialog_options.cpp:259
msgid "Wires - Bus orient"
msgstr "Fils-Bus Orient"
#: eeschema/dialog_options.cpp:282
msgid "Auto increment params"
msgstr "Auto incrément params"
#: eeschema/dialog_options.cpp:298
msgid "Delta Label:"
msgstr "Incrément Label:"
#: eeschema/dialog_options.cpp:315
msgid "Default Label Size"
msgstr "Taille Label par défaut"
#: eeschema/class_libentry.cpp:67 #: eeschema/class_libentry.cpp:67
msgid "none" msgid "none"
msgstr "rien" msgstr "rien"
...@@ -10040,50 +9999,6 @@ msgstr "Remplissage en &avant plan" ...@@ -10040,50 +9999,6 @@ msgstr "Remplissage en &avant plan"
msgid "Fill &background" msgid "Fill &background"
msgstr "Remplissage en a&rriere plan" msgstr "Remplissage en a&rriere plan"
#: eeschema/dialog_annotate_base.cpp:22
msgid "Scope"
msgstr "Sélection"
#: eeschema/dialog_annotate_base.cpp:31
msgid "Use the &entire schematic"
msgstr "Utiliser la schématique &entière"
#: eeschema/dialog_annotate_base.cpp:34
msgid "Use the current &page only"
msgstr "Utiliser la &feuille active uniquement"
#: eeschema/dialog_annotate_base.cpp:40
msgid "&Keep existing annotation"
msgstr "&Garder l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:43
msgid "&Reset existing annotation"
msgstr "&Supprimer l'annotation existante"
#: eeschema/dialog_annotate_base.cpp:51
msgid "Annotation Order"
msgstr "Sens de Annotation"
#: eeschema/dialog_annotate_base.cpp:66
msgid "Sort Components by &X Position"
msgstr "Trier les Composants par Position &X"
#: eeschema/dialog_annotate_base.cpp:77
msgid "Sort Components by &Y Position"
msgstr "Trier les Composants par Position &Y"
#: eeschema/dialog_annotate_base.cpp:88
msgid "Sort Components by &Value"
msgstr "Trier Composants par &Valeur"
#: eeschema/dialog_annotate_base.cpp:106
msgid "Clear Annotation"
msgstr "Suppression Annotation"
#: eeschema/dialog_annotate_base.cpp:109
msgid "Annotation"
msgstr "Annotation"
#: eeschema/save_schemas.cpp:66 #: eeschema/save_schemas.cpp:66
msgid "Schematic Files" msgid "Schematic Files"
msgstr "Fichiers Schématiques" msgstr "Fichiers Schématiques"
...@@ -10117,6 +10032,54 @@ msgstr " a été créé par une version plus ancienne de Eeschema. Il sera enreg ...@@ -10117,6 +10032,54 @@ msgstr " a été créé par une version plus ancienne de Eeschema. Il sera enreg
msgid "Done Loading " msgid "Done Loading "
msgstr "Chargement terminé " msgstr "Chargement terminé "
#: eeschema/dialog_eeschema_options_base.cpp:34
msgid "Mesurement &units:"
msgstr "&Unités de mesure:"
#: eeschema/dialog_eeschema_options_base.cpp:46
msgid "&Grid size:"
msgstr "Dim &Grille:"
#: eeschema/dialog_eeschema_options_base.cpp:59
msgid "Default &line width:"
msgstr "Epaiss. &ligne par défaut:"
#: eeschema/dialog_eeschema_options_base.cpp:70
msgid "Default text &size:"
msgstr "Dim. &texte par défaut:"
#: eeschema/dialog_eeschema_options_base.cpp:81
msgid "Repeat draw item &horizontal displacement:"
msgstr "Déplacement &horizontal en répétition d'items:"
#: eeschema/dialog_eeschema_options_base.cpp:92
msgid "Repeat draw item &vertical displacement:"
msgstr "Déplacement &vertical en répétition d'items:"
#: eeschema/dialog_eeschema_options_base.cpp:103
msgid "&Repeat label increment:"
msgstr "Incémentation des labels en répétition:"
#: eeschema/dialog_eeschema_options_base.cpp:118
msgid "Show g&rid"
msgstr "Afficher g&rille"
#: eeschema/dialog_eeschema_options_base.cpp:122
msgid "Show hi&dden pins"
msgstr "Force affichage des pins &invisibles"
#: eeschema/dialog_eeschema_options_base.cpp:126
msgid "Enable automatic &panning"
msgstr "Active le \"&panning\" automatique"
#: eeschema/dialog_eeschema_options_base.cpp:130
msgid "Allow buses and wires to be placed in any &orientation"
msgstr "Autorise les bus et fils a être placés en &orientation quelconque"
#: eeschema/dialog_eeschema_options_base.cpp:134
msgid "Show p&age limits"
msgstr " Afficher limites de p&age"
#: eeschema/component_wizard/dialog_component_setup.cpp:137 #: eeschema/component_wizard/dialog_component_setup.cpp:137
msgid "Quick KICAD Library Component Builder" msgid "Quick KICAD Library Component Builder"
msgstr "" msgstr ""
...@@ -11110,7 +11073,7 @@ msgstr "Masque soudure composant (*.GTS)|*.GTS;*.gts|" ...@@ -11110,7 +11073,7 @@ msgstr "Masque soudure composant (*.GTS)|*.GTS;*.gts|"
#: gerbview/files.cpp:122 #: gerbview/files.cpp:122
msgid "Bottom overlay (*.GBO)|*.GBO;*.gbo|" msgid "Bottom overlay (*.GBO)|*.GBO;*.gbo|"
msgstr "" msgstr "Simple face, CMS coté Cuivre."
#: gerbview/files.cpp:123 #: gerbview/files.cpp:123
msgid "Top overlay (*.GTO)|*.GTO;*.gto|" msgid "Top overlay (*.GTO)|*.GTO;*.gto|"
...@@ -11665,6 +11628,10 @@ msgstr "Tous les fichiers (*)|*" ...@@ -11665,6 +11628,10 @@ msgstr "Tous les fichiers (*)|*"
msgid " (\"):" msgid " (\"):"
msgstr " (\"):" msgstr " (\"):"
#: common/common.cpp:257
msgid "inches"
msgstr "Pouces"
#: common/common.cpp:265 #: common/common.cpp:265
msgid "centimeters" msgid "centimeters"
msgstr "centimètres" msgstr "centimètres"
...@@ -12016,12 +11983,10 @@ msgid "Back View" ...@@ -12016,12 +11983,10 @@ msgid "Back View"
msgstr "Vue arrière" msgstr "Vue arrière"
#: 3d-viewer/3d_canvas.cpp:353 #: 3d-viewer/3d_canvas.cpp:353
#: 3d-viewer/3d_toolbar.cpp:85
msgid "Move left <-" msgid "Move left <-"
msgstr "Vers la gauche <-" msgstr "Vers la gauche <-"
#: 3d-viewer/3d_canvas.cpp:358 #: 3d-viewer/3d_canvas.cpp:358
#: 3d-viewer/3d_toolbar.cpp:88
msgid "Move right ->" msgid "Move right ->"
msgstr "Vers la droite ->" msgstr "Vers la droite ->"
...@@ -12315,7 +12280,6 @@ msgid "Exchange Modules" ...@@ -12315,7 +12280,6 @@ msgid "Exchange Modules"
msgstr "Echange modules:" msgstr "Echange modules:"
#: pcbnew/dialog_edit_module_for_Modedit_base.h:105 #: pcbnew/dialog_edit_module_for_Modedit_base.h:105
#: pcbnew/dialog_edit_module_for_BoardEditor_base.h:118
msgid "Module properties" msgid "Module properties"
msgstr "Propriétés du Module" msgstr "Propriétés du Module"
...@@ -12331,10 +12295,6 @@ msgstr "Edition Globale de Pistes et Vias" ...@@ -12331,10 +12295,6 @@ msgstr "Edition Globale de Pistes et Vias"
msgid "Sheet properties" msgid "Sheet properties"
msgstr "Propriétés de la feuille" msgstr "Propriétés de la feuille"
#: eeschema/dialog_options.h:55
msgid "General Options"
msgstr "Options Générales"
#: eeschema/eelayer.h:35 #: eeschema/eelayer.h:35
msgid "EESchema Colors" msgid "EESchema Colors"
msgstr "Couleurs dans EESchema" msgstr "Couleurs dans EESchema"
...@@ -12451,6 +12411,10 @@ msgstr "Propriétés des Champs" ...@@ -12451,6 +12411,10 @@ msgstr "Propriétés des Champs"
msgid "Pin Properties" msgid "Pin Properties"
msgstr "Propriétés des Pins" msgstr "Propriétés des Pins"
#: eeschema/dialog_annotate_base.h:77
msgid "Annotate Schematic"
msgstr "Annotation de la Schématique"
#: eeschema/dialog_edit_component_in_lib_base.h:107 #: eeschema/dialog_edit_component_in_lib_base.h:107
msgid "Lib Component Properties" msgid "Lib Component Properties"
msgstr "Propriétés du composant librairie" msgstr "Propriétés du composant librairie"
...@@ -12463,6 +12427,10 @@ msgstr "Propriétés de l'Elément Graphique" ...@@ -12463,6 +12427,10 @@ msgstr "Propriétés de l'Elément Graphique"
msgid "EESchema Erc" msgid "EESchema Erc"
msgstr "EESchema Erc" msgstr "EESchema Erc"
#: eeschema/dialog_eeschema_options_base.h:77
msgid "Schematic Editor Options"
msgstr "Options de l'Editeur de Schematique"
#: eeschema/dialog_build_BOM_base.h:69 #: eeschema/dialog_build_BOM_base.h:69
msgid "List of Material" msgid "List of Material"
msgstr "Liste du Matériel" msgstr "Liste du Matériel"
...@@ -12623,6 +12591,42 @@ msgstr "Options d'Affichage" ...@@ -12623,6 +12591,42 @@ msgstr "Options d'Affichage"
msgid "Page Settings" msgid "Page Settings"
msgstr "Ajustage opt Page" msgstr "Ajustage opt Page"
#~ msgid "Delta Step X"
#~ msgstr "Incrément X"
#~ msgid "Delta Step Y"
#~ msgstr "Incrément Y"
#~ msgid "Draw Options:"
#~ msgstr "Options de Tracé:"
#~ msgid "Normal (50 mils)"
#~ msgstr "Normal (50 mils)"
#~ msgid "Small (25 mils)"
#~ msgstr "Petit (25 mils)"
#~ msgid "Very small (10 mils)"
#~ msgstr "Très petit (10 mils)"
#~ msgid "Special (5 mils)"
#~ msgstr "Spécial (5 mils)"
#~ msgid "Special (2 mils)"
#~ msgstr "Spécial (2 mils)"
#~ msgid "Special (1 mil)"
#~ msgstr "Spécial (1 mil)"
#~ msgid "Show alls"
#~ msgstr "Tout Afficher"
#~ msgid "Show pins"
#~ msgstr "Montrer Pins"
#~ msgid "millimeter"
#~ msgstr "millimètre"
#~ msgid "Horiz/Vertical"
#~ msgstr "Horiz/Vertical"
#~ msgid "Wires - Bus orient"
#~ msgstr "Fils-Bus Orient"
#~ msgid "Auto increment params"
#~ msgstr "Auto incrément params"
#~ msgid "Delta Label:"
#~ msgstr "Incrément Label:"
#~ msgid "Default Label Size"
#~ msgstr "Taille Label par défaut"
#~ msgid "General Options"
#~ msgstr "Options Générales"
#~ msgid "" #~ msgid ""
#~ "Check this option for power symbols.\n" #~ "Check this option for power symbols.\n"
#~ "Power symbols have specific properties" #~ "Power symbols have specific properties"
...@@ -12756,8 +12760,6 @@ msgstr "Ajustage opt Page" ...@@ -12756,8 +12760,6 @@ msgstr "Ajustage opt Page"
#~ msgstr "Ceci est l'espace entre pads et le masque" #~ msgstr "Ceci est l'espace entre pads et le masque"
#~ msgid "Schematic hierarchy navigator" #~ msgid "Schematic hierarchy navigator"
#~ msgstr "Navigation dans la hiérarchie" #~ msgstr "Navigation dans la hiérarchie"
#~ msgid "Schematic Annotation"
#~ msgstr "Annotation des composants"
#~ msgid "Show Hidden Pins" #~ msgid "Show Hidden Pins"
#~ msgstr "Force affichage des pins invisibles" #~ msgstr "Force affichage des pins invisibles"
#~ msgid "Setting Libraries, Directories and others..." #~ msgid "Setting Libraries, Directories and others..."
...@@ -13038,8 +13040,6 @@ msgstr "Ajustage opt Page" ...@@ -13038,8 +13040,6 @@ msgstr "Ajustage opt Page"
#~ msgstr "Entrer la largeur de piste courante" #~ msgstr "Entrer la largeur de piste courante"
#~ msgid "This is the clearance between tracks, vias and pads for DRC." #~ msgid "This is the clearance between tracks, vias and pads for DRC."
#~ msgstr "Ceci est l'isolation entre pistes, vias et pads pour le calcul DRC." #~ msgstr "Ceci est l'isolation entre pistes, vias et pads pour le calcul DRC."
#~ msgid "Delete units"
#~ msgstr "Supprimer unité"
#~ msgid "Create pins for convert items." #~ msgid "Create pins for convert items."
#~ msgstr "Créér les pins des unitées converties." #~ msgstr "Créér les pins des unitées converties."
#~ msgid "Part as \"De Morgan\" anymore" #~ msgid "Part as \"De Morgan\" anymore"
......
...@@ -34,111 +34,151 @@ ...@@ -34,111 +34,151 @@
/* local variables */ /* local variables */
/* Hotkey list: */ /* Hotkey list: */
static Ki_HotkeyInfo HkSwitch2CopperLayer(wxT("Switch to Copper layer"), static Ki_HotkeyInfo HkSwitch2CopperLayer( wxT( "Switch to Copper layer" ),
HK_SWITCH_LAYER_TO_COPPER, WXK_PAGEUP); HK_SWITCH_LAYER_TO_COPPER, WXK_PAGEUP );
static Ki_HotkeyInfo HkSwitch2ComponentLayer(wxT("Switch to Component layer"), static Ki_HotkeyInfo HkSwitch2ComponentLayer( wxT( "Switch to Component layer" ),
HK_SWITCH_LAYER_TO_COMPONENT, WXK_PAGEDOWN); HK_SWITCH_LAYER_TO_COMPONENT, WXK_PAGEDOWN );
static Ki_HotkeyInfo HkSwitch2InnerLayer1(wxT("Switch to Inner layer 1"), static Ki_HotkeyInfo HkSwitch2InnerLayer1( wxT( "Switch to Inner layer 1" ),
HK_SWITCH_LAYER_TO_INNER1, WXK_F5); HK_SWITCH_LAYER_TO_INNER1, WXK_F5 );
static Ki_HotkeyInfo HkSwitch2InnerLayer2(wxT("Switch to Inner layer 2"), static Ki_HotkeyInfo HkSwitch2InnerLayer2( wxT( "Switch to Inner layer 2" ),
HK_SWITCH_LAYER_TO_INNER2, WXK_F6); HK_SWITCH_LAYER_TO_INNER2, WXK_F6 );
static Ki_HotkeyInfo HkSwitch2InnerLayer3(wxT("Switch to Inner layer 3"), static Ki_HotkeyInfo HkSwitch2InnerLayer3( wxT( "Switch to Inner layer 3" ),
HK_SWITCH_LAYER_TO_INNER3, WXK_F7); HK_SWITCH_LAYER_TO_INNER3, WXK_F7 );
static Ki_HotkeyInfo HkSwitch2InnerLayer4(wxT("Switch to Inner layer 4"), static Ki_HotkeyInfo HkSwitch2InnerLayer4( wxT( "Switch to Inner layer 4" ),
HK_SWITCH_LAYER_TO_INNER4, WXK_F8); HK_SWITCH_LAYER_TO_INNER4, WXK_F8 );
static Ki_HotkeyInfo HkSwitch2InnerLayer5(wxT("Switch to Inner layer 5"), static Ki_HotkeyInfo HkSwitch2InnerLayer5( wxT( "Switch to Inner layer 5" ),
HK_SWITCH_LAYER_TO_INNER5, WXK_F9); HK_SWITCH_LAYER_TO_INNER5, WXK_F9 );
static Ki_HotkeyInfo HkSwitch2InnerLayer6(wxT("Switch to Inner layer 6"), static Ki_HotkeyInfo HkSwitch2InnerLayer6( wxT( "Switch to Inner layer 6" ),
HK_SWITCH_LAYER_TO_INNER6, WXK_F10); HK_SWITCH_LAYER_TO_INNER6, WXK_F10 );
static Ki_HotkeyInfo HkSwitch2NextCopperLayer(wxT("Switch to Next Layer"), static Ki_HotkeyInfo HkSwitch2NextCopperLayer( wxT( "Switch to Next Layer" ),
HK_SWITCH_LAYER_TO_NEXT, '+'); HK_SWITCH_LAYER_TO_NEXT, '+' );
static Ki_HotkeyInfo HkSwitch2PreviousCopperLayer(wxT( static Ki_HotkeyInfo HkSwitch2PreviousCopperLayer( wxT(
"Switch to Previous Layer"), HK_SWITCH_LAYER_TO_PREVIOUS, '-'); "Switch to Previous Layer" ),
HK_SWITCH_LAYER_TO_PREVIOUS, '-' );
static Ki_HotkeyInfo HkSavefile(wxT("Save board"), HK_SAVE_BOARD, 'S'
+ GR_KB_CTRL); static Ki_HotkeyInfo HkSavefile( wxT( "Save board" ), HK_SAVE_BOARD, 'S'
static Ki_HotkeyInfo HkLoadfile(wxT("Load board"), HK_LOAD_BOARD, 'L' + GR_KB_CTRL );
+ GR_KB_CTRL); static Ki_HotkeyInfo HkLoadfile( wxT( "Load board" ), HK_LOAD_BOARD, 'L'
static Ki_HotkeyInfo HkFindItem(wxT("Find Item"), HK_FIND_ITEM, 'F' + GR_KB_CTRL );
+ GR_KB_CTRL); static Ki_HotkeyInfo HkFindItem( wxT( "Find Item" ), HK_FIND_ITEM, 'F'
static Ki_HotkeyInfo HkBackspace(wxT("Delete track segment"), HK_BACK_SPACE, + GR_KB_CTRL );
WXK_BACK); static Ki_HotkeyInfo HkBackspace( wxT( "Delete track segment" ), HK_BACK_SPACE,
static Ki_HotkeyInfo HkAddVia(wxT("Add Via"), HK_ADD_VIA, 'V'); WXK_BACK );
static Ki_HotkeyInfo HkAddMicroVia(wxT("Add MicroVia"), HK_ADD_MICROVIA, 'V' static Ki_HotkeyInfo HkAddVia( wxT( "Add Via" ), HK_ADD_VIA, 'V' );
+ GR_KB_CTRL); static Ki_HotkeyInfo HkAddMicroVia( wxT( "Add MicroVia" ), HK_ADD_MICROVIA, 'V'
static Ki_HotkeyInfo HkEndTrack(wxT("End Track"), HK_END_TRACK, WXK_END); + GR_KB_CTRL );
static Ki_HotkeyInfo HkFlipFootprint(wxT("Flip Footprint"), HK_FLIP_FOOTPRINT, static Ki_HotkeyInfo HkEndTrack( wxT( "End Track" ), HK_END_TRACK, WXK_END );
'F'); static Ki_HotkeyInfo HkFlipFootprint( wxT( "Flip Footprint" ), HK_FLIP_FOOTPRINT,
static Ki_HotkeyInfo HkRotateFootprint(wxT("Rotate Footprint"), 'F' );
HK_ROTATE_FOOTPRINT, 'R'); static Ki_HotkeyInfo HkRotateFootprint( wxT( "Rotate Footprint" ),
static Ki_HotkeyInfo HkMoveFootprint(wxT("Move Footprint"), HK_MOVE_FOOTPRINT, HK_ROTATE_FOOTPRINT, 'R' );
'M'); static Ki_HotkeyInfo HkMoveFootprint( wxT( "Move Footprint" ), HK_MOVE_FOOTPRINT,
static Ki_HotkeyInfo HkDragFootprint(wxT("Drag Footprint"), HK_DRAG_FOOTPRINT, 'M' );
'G'); static Ki_HotkeyInfo HkDragFootprint( wxT( "Drag Footprint" ), HK_DRAG_FOOTPRINT,
static Ki_HotkeyInfo HkGetAndMoveFootprint(wxT("Get and Move Footprint"), 'G' );
HK_GET_AND_MOVE_FOOTPRINT, 'T'); static Ki_HotkeyInfo HkGetAndMoveFootprint( wxT( "Get and Move Footprint" ),
static Ki_HotkeyInfo HkLock_Unlock_Footprint(wxT("Lock/Unlock Footprint"), HK_GET_AND_MOVE_FOOTPRINT, 'T' );
HK_LOCK_UNLOCK_FOOTPRINT, 'L'); static Ki_HotkeyInfo HkLock_Unlock_Footprint( wxT( "Lock/Unlock Footprint" ),
static Ki_HotkeyInfo HkDelete(wxT("Delete Track or Footprint"), HK_DELETE, HK_LOCK_UNLOCK_FOOTPRINT, 'L' );
WXK_DELETE); static Ki_HotkeyInfo HkDelete( wxT( "Delete Track or Footprint" ), HK_DELETE,
static Ki_HotkeyInfo HkResetLocalCoord(wxT("Reset local coord."), WXK_DELETE );
HK_RESET_LOCAL_COORD, ' '); static Ki_HotkeyInfo HkResetLocalCoord( wxT( "Reset local coord." ),
HK_RESET_LOCAL_COORD, ' ' );
static Ki_HotkeyInfo HkZoomAuto( wxT( "Zoom Auto" ), HK_ZOOM_AUTO, WXK_HOME ); static Ki_HotkeyInfo HkZoomAuto( wxT( "Zoom Auto" ), HK_ZOOM_AUTO, WXK_HOME );
static Ki_HotkeyInfo HkZoomCenter(wxT("Zoom Center"), HK_ZOOM_CENTER, WXK_F4); static Ki_HotkeyInfo HkZoomCenter( wxT( "Zoom Center" ), HK_ZOOM_CENTER, WXK_F4 );
static Ki_HotkeyInfo HkZoomRedraw(wxT("Zoom Redraw"), HK_ZOOM_REDRAW, WXK_F3); static Ki_HotkeyInfo HkZoomRedraw( wxT( "Zoom Redraw" ), HK_ZOOM_REDRAW, WXK_F3 );
static Ki_HotkeyInfo HkZoomOut(wxT("Zoom Out"), HK_ZOOM_OUT, WXK_F2); static Ki_HotkeyInfo HkZoomOut( wxT( "Zoom Out" ), HK_ZOOM_OUT, WXK_F2 );
static Ki_HotkeyInfo HkZoomIn(wxT("Zoom In"), HK_ZOOM_IN, WXK_F1); static Ki_HotkeyInfo HkZoomIn( wxT( "Zoom In" ), HK_ZOOM_IN, WXK_F1 );
static Ki_HotkeyInfo HkHelp(wxT("Help: this message"), HK_HELP, '?'); static Ki_HotkeyInfo HkHelp( wxT( "Help: this message" ), HK_HELP, '?' );
static Ki_HotkeyInfo HkSwitchUnits(wxT("Switch Units"), HK_SWITCH_UNITS, 'U' static Ki_HotkeyInfo HkSwitchUnits( wxT( "Switch Units" ), HK_SWITCH_UNITS, 'U'
+ GR_KB_CTRL); + GR_KB_CTRL );
static Ki_HotkeyInfo HkTrackDisplayMode(wxT("Track Display Mode"), static Ki_HotkeyInfo HkTrackDisplayMode( wxT( "Track Display Mode" ),
HK_SWITCH_TRACK_DISPLAY_MODE, 'K'); HK_SWITCH_TRACK_DISPLAY_MODE, 'K' );
static Ki_HotkeyInfo HkAddModule(wxT("Add Module"), HK_ADD_MODULE, 'O'); static Ki_HotkeyInfo HkAddModule( wxT( "Add Module" ), HK_ADD_MODULE, 'O' );
static Ki_HotkeyInfo HkAddTrack(wxT("Add Track or Via"), HK_ADD_TRACK, 'J'); static Ki_HotkeyInfo HkAddTrack( wxT( "Add Track or Via" ), HK_ADD_TRACK, 'J' );
// List of common hotkey descriptors // List of common hotkey descriptors
Ki_HotkeyInfo Ki_HotkeyInfo
* s_Common_Hotkey_List[] = { &HkHelp, &HkZoomIn, &HkZoomOut, * s_Common_Hotkey_List[] =
&HkZoomRedraw, &HkZoomCenter, &HkZoomAuto, {
&HkSwitchUnits, &HkResetLocalCoord, NULL }; &HkHelp, &HkZoomIn, &HkZoomOut,
&HkZoomRedraw, &HkZoomCenter, &HkZoomAuto,
&HkSwitchUnits, &HkResetLocalCoord, NULL
};
// List of hotkey descriptors for pcbnew // List of hotkey descriptors for pcbnew
Ki_HotkeyInfo* s_board_edit_Hotkey_List[] = { &HkTrackDisplayMode, &HkDelete, Ki_HotkeyInfo* s_board_edit_Hotkey_List[] =
&HkBackspace, &HkAddVia, &HkAddMicroVia, &HkEndTrack, &HkMoveFootprint, {
&HkFlipFootprint, &HkRotateFootprint, &HkDragFootprint, &HkTrackDisplayMode, &HkDelete,
&HkGetAndMoveFootprint, &HkLock_Unlock_Footprint, &HkSavefile, &HkBackspace, &HkAddVia, &HkAddMicroVia,
&HkLoadfile, &HkFindItem, &HkSwitch2CopperLayer, &HkSwitch2InnerLayer1, &HkEndTrack, &HkMoveFootprint,
&HkSwitch2InnerLayer2, &HkSwitch2InnerLayer3, &HkSwitch2InnerLayer4, &HkFlipFootprint, &HkRotateFootprint, &HkDragFootprint,
&HkSwitch2InnerLayer5, &HkSwitch2InnerLayer6, &HkSwitch2ComponentLayer, &HkGetAndMoveFootprint, &HkLock_Unlock_Footprint, &HkSavefile,
&HkSwitch2NextCopperLayer, &HkSwitch2PreviousCopperLayer, &HkAddModule, &HkLoadfile, &HkFindItem, &HkSwitch2CopperLayer,
&HkAddTrack, NULL }; &HkSwitch2InnerLayer1,
&HkSwitch2InnerLayer2, &HkSwitch2InnerLayer3, &HkSwitch2InnerLayer4,
&HkSwitch2InnerLayer5, &HkSwitch2InnerLayer6, &HkSwitch2ComponentLayer,
&HkSwitch2NextCopperLayer, &HkSwitch2PreviousCopperLayer,&HkAddModule,
&HkAddTrack, NULL
};
// List of hotkey descriptors for the module editor // List of hotkey descriptors for the module editor
Ki_HotkeyInfo* s_module_edit_Hotkey_List[] = { NULL }; Ki_HotkeyInfo* s_module_edit_Hotkey_List[] = { NULL };
// list of sections and corresponding hotkey list for pcbnew (used to create an hotkey config file) // list of sections and corresponding hotkey list for pcbnew (used to create an hotkey config file)
struct Ki_HotkeyInfoSectionDescriptor s_Pcbnew_Editor_Hokeys_Descr[] = { { struct Ki_HotkeyInfoSectionDescriptor s_Pcbnew_Editor_Hokeys_Descr[] = { {
&g_CommonSectionTag, s_Common_Hotkey_List, "Common keys" }, &g_CommonSectionTag,
{ &g_BoardEditorSectionTag, s_board_edit_Hotkey_List, s_Common_Hotkey_List,
"Board editor keys" }, { &g_ModuleEditSectionTag, "Common keys"
s_module_edit_Hotkey_List, "Footprint editor keys" }, { NULL, },
NULL, NULL } }; {
&
g_BoardEditorSectionTag,
s_board_edit_Hotkey_List,
"Board editor keys"
}, {
&
g_ModuleEditSectionTag,
s_module_edit_Hotkey_List,
"Footprint editor keys"
}, {
NULL,
NULL, NULL
} };
// list of sections and corresponding hotkey list for the board editor (used to list current hotkeys) // list of sections and corresponding hotkey list for the board editor (used to list current hotkeys)
struct Ki_HotkeyInfoSectionDescriptor s_Board_Editor_Hokeys_Descr[] = { { struct Ki_HotkeyInfoSectionDescriptor s_Board_Editor_Hokeys_Descr[] = { {
&g_CommonSectionTag, s_Common_Hotkey_List, NULL }, { &g_CommonSectionTag,
&g_BoardEditorSectionTag, s_board_edit_Hotkey_List, NULL }, { NULL, s_Common_Hotkey_List,
NULL, NULL } }; NULL
}, {
&
g_BoardEditorSectionTag,
s_board_edit_Hotkey_List,
NULL
}, {
NULL,
NULL, NULL
} };
// list of sections and corresponding hotkey list for the footprint editor (used to list current hotkeys) // list of sections and corresponding hotkey list for the footprint editor (used to list current hotkeys)
struct Ki_HotkeyInfoSectionDescriptor s_Module_Editor_Hokeys_Descr[] = { { struct Ki_HotkeyInfoSectionDescriptor s_Module_Editor_Hokeys_Descr[] = { {
&g_CommonSectionTag, s_Common_Hotkey_List, NULL }, { &g_CommonSectionTag,
&g_ModuleEditSectionTag, s_module_edit_Hotkey_List, NULL }, { NULL, s_Common_Hotkey_List,
NULL, NULL } }; NULL
}, {
&
g_ModuleEditSectionTag,
s_module_edit_Hotkey_List,
NULL
}, {
NULL,
NULL, NULL
} };
/***********************************************************/ /***********************************************************/
void WinEDA_PcbFrame::OnHotKey(wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct) void WinEDA_PcbFrame::OnHotKey( wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct )
/***********************************************************/ /***********************************************************/
/* Hot keys. Some commands are relatives to the item under the mouse cursor /* Hot keys. Some commands are relatives to the item under the mouse cursor
...@@ -149,463 +189,497 @@ void WinEDA_PcbFrame::OnHotKey(wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct) ...@@ -149,463 +189,497 @@ void WinEDA_PcbFrame::OnHotKey(wxDC* DC, int hotkey, EDA_BaseStruct* DrawStruct)
*/ */
{ {
wxCommandEvent cmd(wxEVT_COMMAND_MENU_SELECTED); wxCommandEvent cmd( wxEVT_COMMAND_MENU_SELECTED );
cmd.SetEventObject(this);
cmd.SetEventObject( this );
bool PopupOn = (GetCurItem() && GetCurItem()->m_Flags);
bool PopupOn = (GetCurItem() && GetCurItem()->m_Flags);
bool ItemFree = (GetCurItem() == 0 || GetCurItem()->m_Flags == 0);
bool ItemFree = (GetCurItem() == 0 || GetCurItem()->m_Flags == 0);
if (hotkey == 0)
return; if( hotkey == 0 )
return;
MODULE* module = NULL;
MODULE* module = NULL;
// Remap the control key Ctrl A (0x01) to GR_KB_CTRL + 'A' (just easier to handle...)
if ((hotkey & GR_KB_CTRL) != 0) // Remap the control key Ctrl A (0x01) to GR_KB_CTRL + 'A' (just easier to handle...)
hotkey += 'A' - 1; if( (hotkey & GR_KB_CTRL) != 0 )
hotkey += 'A' - 1;
/* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */
if ((hotkey >= 'a') && (hotkey <= 'z')) /* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */
hotkey += 'A' - 'a'; if( (hotkey >= 'a') && (hotkey <= 'z') )
hotkey += 'A' - 'a';
Ki_HotkeyInfo * HK_Descr = GetDescriptorFromHotkey(hotkey,
s_Common_Hotkey_List); Ki_HotkeyInfo* HK_Descr = GetDescriptorFromHotkey( hotkey,
s_Common_Hotkey_List );
if (HK_Descr == NULL)
HK_Descr = GetDescriptorFromHotkey(hotkey, s_board_edit_Hotkey_List); if( HK_Descr == NULL )
HK_Descr = GetDescriptorFromHotkey( hotkey, s_board_edit_Hotkey_List );
if (HK_Descr == NULL)
return; if( HK_Descr == NULL )
return;
int ll;
int ll;
switch (HK_Descr->m_Idcommand) {
default: switch( HK_Descr->m_Idcommand )
case HK_NOT_FOUND: {
return; default:
break; case HK_NOT_FOUND:
return;
case HK_SWITCH_LAYER_TO_PREVIOUS: break;
ll = GetScreen()->m_Active_Layer;
if ((ll <= COPPER_LAYER_N) || (ll > CMP_N)) case HK_SWITCH_LAYER_TO_PREVIOUS:
break; ll = GetScreen()->m_Active_Layer;
if (GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2) // Single layer if( (ll <= COPPER_LAYER_N) || (ll > CMP_N) )
ll = COPPER_LAYER_N; break;
else if (ll == CMP_N) if( GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2 ) // Single layer
ll = MAX(COPPER_LAYER_N, ll = COPPER_LAYER_N;
GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2); else if( ll == CMP_N )
else ll = MAX( COPPER_LAYER_N,
ll--; GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2 );
SwitchLayer(DC, ll); else
break; ll--;
SwitchLayer( DC, ll );
case HK_SWITCH_LAYER_TO_NEXT: break;
ll = GetScreen()->m_Active_Layer;
if ((ll < COPPER_LAYER_N) || (ll >= CMP_N)) case HK_SWITCH_LAYER_TO_NEXT:
break; ll = GetScreen()->m_Active_Layer;
if (GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2) // Single layer if( (ll < COPPER_LAYER_N) || (ll >= CMP_N) )
ll = COPPER_LAYER_N; break;
else if (ll >= GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2) if( GetBoard()->m_BoardSettings->GetCopperLayerCount() < 2 ) // Single layer
ll = CMP_N; ll = COPPER_LAYER_N;
else else if( ll >= GetBoard()->m_BoardSettings->GetCopperLayerCount() - 2 )
ll++; ll = CMP_N;
SwitchLayer(DC, ll); else
break; ll++;
SwitchLayer( DC, ll );
case HK_SWITCH_LAYER_TO_COMPONENT: break;
SwitchLayer(DC, CMP_N);
break; case HK_SWITCH_LAYER_TO_COMPONENT:
SwitchLayer( DC, CMP_N );
case HK_SWITCH_LAYER_TO_COPPER: break;
SwitchLayer(DC, COPPER_LAYER_N);
break; case HK_SWITCH_LAYER_TO_COPPER:
SwitchLayer( DC, COPPER_LAYER_N );
case HK_SWITCH_LAYER_TO_INNER1: break;
SwitchLayer(DC, LAYER_N_2);
break; case HK_SWITCH_LAYER_TO_INNER1:
SwitchLayer( DC, LAYER_N_2 );
case HK_SWITCH_LAYER_TO_INNER2: break;
SwitchLayer(DC, LAYER_N_3);
break; case HK_SWITCH_LAYER_TO_INNER2:
SwitchLayer( DC, LAYER_N_3 );
case HK_SWITCH_LAYER_TO_INNER3: break;
SwitchLayer(DC, LAYER_N_4);
break; case HK_SWITCH_LAYER_TO_INNER3:
SwitchLayer( DC, LAYER_N_4 );
case HK_SWITCH_LAYER_TO_INNER4: break;
SwitchLayer(DC, LAYER_N_5);
break; case HK_SWITCH_LAYER_TO_INNER4:
SwitchLayer( DC, LAYER_N_5 );
case HK_SWITCH_LAYER_TO_INNER5: break;
SwitchLayer(DC, LAYER_N_6);
break; case HK_SWITCH_LAYER_TO_INNER5:
SwitchLayer( DC, LAYER_N_6 );
case HK_SWITCH_LAYER_TO_INNER6: break;
SwitchLayer(DC, LAYER_N_7);
break; case HK_SWITCH_LAYER_TO_INNER6:
SwitchLayer( DC, LAYER_N_7 );
case HK_HELP: // Display Current hotkey list break;
DisplayHotkeyList(this, s_Board_Editor_Hokeys_Descr);
break; case HK_HELP: // Display Current hotkey list
DisplayHotkeyList( this, s_Board_Editor_Hokeys_Descr );
case HK_ZOOM_IN: break;
cmd.SetId(ID_POPUP_ZOOM_IN);
GetEventHandler()->ProcessEvent(cmd); case HK_ZOOM_IN:
break; cmd.SetId( ID_POPUP_ZOOM_IN );
GetEventHandler()->ProcessEvent( cmd );
case HK_ZOOM_OUT: break;
cmd.SetId(ID_POPUP_ZOOM_OUT);
GetEventHandler()->ProcessEvent(cmd); case HK_ZOOM_OUT:
break; cmd.SetId( ID_POPUP_ZOOM_OUT );
GetEventHandler()->ProcessEvent( cmd );
case HK_ZOOM_REDRAW: break;
cmd.SetId(ID_ZOOM_REDRAW);
GetEventHandler()->ProcessEvent(cmd); case HK_ZOOM_REDRAW:
break; cmd.SetId( ID_ZOOM_REDRAW );
GetEventHandler()->ProcessEvent( cmd );
case HK_ZOOM_CENTER: break;
cmd.SetId(ID_POPUP_ZOOM_CENTER);
GetEventHandler()->ProcessEvent(cmd); case HK_ZOOM_CENTER:
break; cmd.SetId( ID_POPUP_ZOOM_CENTER );
case HK_ADD_MODULE: GetEventHandler()->ProcessEvent( cmd );
cmd.SetId(ID_COMPONENT_BUTT); break;
GetEventHandler()->ProcessEvent(cmd);
break; case HK_ADD_MODULE:
case HK_ADD_TRACK: cmd.SetId( ID_COMPONENT_BUTT );
cmd.SetId(ID_TRACK_BUTT); GetEventHandler()->ProcessEvent( cmd );
GetEventHandler()->ProcessEvent(cmd); break;
break;
case HK_ADD_TRACK:
case HK_ZOOM_AUTO: cmd.SetId( ID_TRACK_BUTT );
cmd.SetId(ID_ZOOM_PAGE); GetEventHandler()->ProcessEvent( cmd );
GetEventHandler()->ProcessEvent(cmd); break;
break;
case HK_ZOOM_AUTO:
case HK_RESET_LOCAL_COORD: /*Reset the relative coord */ cmd.SetId( ID_ZOOM_PAGE );
GetScreen()->m_O_Curseur = GetScreen()->m_Curseur; GetEventHandler()->ProcessEvent( cmd );
break; break;
case HK_SWITCH_UNITS: case HK_RESET_LOCAL_COORD: /*Reset the relative coord */
g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES; GetScreen()->m_O_Curseur = GetScreen()->m_Curseur;
break; break;
case HK_SWITCH_TRACK_DISPLAY_MODE: case HK_SWITCH_UNITS:
DisplayOpt.DisplayPcbTrackFill ^= 1; g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES;
DisplayOpt.DisplayPcbTrackFill &= 1; break;
m_DisplayPcbTrackFill = DisplayOpt.DisplayPcbTrackFill;
GetScreen()->SetRefreshReq(); case HK_SWITCH_TRACK_DISPLAY_MODE:
break; DisplayOpt.DisplayPcbTrackFill ^= 1;
DisplayOpt.DisplayPcbTrackFill &= 1;
case HK_DELETE: m_DisplayPcbTrackFill = DisplayOpt.DisplayPcbTrackFill;
OnHotkeyDeleteItem(DC, DrawStruct); GetScreen()->SetRefreshReq();
break; break;
case HK_BACK_SPACE: case HK_DELETE:
if (m_ID_current_state == ID_TRACK_BUTT && GetScreen()->m_Active_Layer OnHotkeyDeleteItem( DC, DrawStruct );
<= CMP_N) { break;
if (ItemFree) {
// no track is currently being edited - select a segment and remove it. case HK_BACK_SPACE:
// @todo: possibly? pass the HK command code to PcbGeneralLocateAndDisplay() so it can restrict its search to specific item types. if( m_ID_current_state == ID_TRACK_BUTT && GetScreen()->m_Active_Layer
// @todo: use PcbGeneralLocateAndDisplay() everywhere in this source file. <= CMP_N )
{
DrawStruct = PcbGeneralLocateAndDisplay(); if( ItemFree )
// don't let backspace delete modules!! {
if (DrawStruct && (DrawStruct->Type() == TYPE_TRACK // no track is currently being edited - select a segment and remove it.
|| DrawStruct->Type() == TYPE_VIA)) { // @todo: possibly? pass the HK command code to PcbGeneralLocateAndDisplay() so it can restrict its search to specific item types.
Delete_Segment(DC, (TRACK*) DrawStruct); // @todo: use PcbGeneralLocateAndDisplay() everywhere in this source file.
SetCurItem(NULL);
} DrawStruct = PcbGeneralLocateAndDisplay();
GetScreen()->SetModify();
} else if (GetCurItem()->Type() == TYPE_TRACK) { // don't let backspace delete modules!!
// then an element is being edited - remove the last segment. if( DrawStruct && (DrawStruct->Type() == TYPE_TRACK
// simple lines for debugger: || DrawStruct->Type() == TYPE_VIA) )
TRACK* track = (TRACK*) GetCurItem(); {
track = Delete_Segment(DC, track); Delete_Segment( DC, (TRACK*) DrawStruct );
SetCurItem(track); SetCurItem( NULL );
GetScreen()->SetModify(); }
} GetScreen()->SetModify();
} }
break; else if( GetCurItem()->Type() == TYPE_TRACK )
{
case HK_END_TRACK: // then an element is being edited - remove the last segment.
if (!ItemFree && (GetCurItem()->Type() == TYPE_TRACK) // simple lines for debugger:
&& ((GetCurItem()->m_Flags & IS_NEW) != 0)) { TRACK* track = (TRACK*) GetCurItem();
// A new track is in progress: call to End_Route() track = Delete_Segment( DC, track );
DrawPanel->MouseToCursorSchema(); SetCurItem( track );
End_Route((TRACK*) GetCurItem(), DC); GetScreen()->SetModify();
} }
break; }
break;
case HK_GET_AND_MOVE_FOOTPRINT:
if (ItemFree) { case HK_END_TRACK:
wxCommandEvent evt; if( !ItemFree && (GetCurItem()->Type() == TYPE_TRACK)
evt.SetId(ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST); && ( (GetCurItem()->m_Flags & IS_NEW) != 0 ) )
Process_Special_Functions(evt); {
} // A new track is in progress: call to End_Route()
break; DrawPanel->MouseToCursorSchema();
End_Route( (TRACK*) GetCurItem(), DC );
case HK_FIND_ITEM: }
if (ItemFree) { break;
wxCommandEvent evt;
evt.SetId(ID_FIND_ITEMS); case HK_GET_AND_MOVE_FOOTPRINT:
Process_Special_Functions(evt); if( ItemFree )
} {
break; wxCommandEvent evt;
evt.SetId( ID_POPUP_PCB_GET_AND_MOVE_MODULE_REQUEST );
case HK_LOAD_BOARD: Process_Special_Functions( evt );
if (ItemFree) { }
// try not to duplicate save, load code etc. break;
wxCommandEvent evt;
evt.SetId(ID_LOAD_FILE); case HK_FIND_ITEM:
Files_io(evt); if( ItemFree )
} {
break; wxCommandEvent evt;
evt.SetId( ID_FIND_ITEMS );
case HK_SAVE_BOARD: Process_Special_Functions( evt );
if (ItemFree) { }
// try not to duplicate save, load code etc. break;
wxCommandEvent evt;
evt.SetId(ID_SAVE_BOARD); case HK_LOAD_BOARD:
Files_io(evt); if( ItemFree )
} {
break; // try not to duplicate save, load code etc.
wxCommandEvent evt;
case HK_ADD_MICROVIA: // Place a micro via if a track is in progress evt.SetId( ID_LOAD_FILE );
if (m_ID_current_state != ID_TRACK_BUTT) Files_io( evt );
return; }
if (ItemFree) // no track in progress: nothing to do break;
break;
if (GetCurItem()->Type() != TYPE_TRACK) // Should not occur case HK_SAVE_BOARD:
return; if( ItemFree )
if ((GetCurItem()->m_Flags & IS_NEW) == 0) {
return; // try not to duplicate save, load code etc.
wxCommandEvent evt;
// place micro via and switch layer evt.SetId( ID_SAVE_BOARD );
if (GetScreen()->IsMicroViaAcceptable()) { Files_io( evt );
int v_type = g_DesignSettings.m_CurrentViaType; }
g_DesignSettings.m_CurrentViaType = VIA_MICROVIA; break;
Other_Layer_Route((TRACK*) GetCurItem(), DC);
g_DesignSettings.m_CurrentViaType = v_type; case HK_ADD_MICROVIA: // Place a micro via if a track is in progress
if (DisplayOpt.ContrastModeDisplay) if( m_ID_current_state != ID_TRACK_BUTT )
GetScreen()->SetRefreshReq(); return;
} if( ItemFree ) // no track in progress: nothing to do
break; break;
if( GetCurItem()->Type() != TYPE_TRACK ) // Should not occur
case HK_ADD_VIA: // Switch to alternate layer and Place a via if a track is in progress return;
if (m_ID_current_state != ID_TRACK_BUTT) if( (GetCurItem()->m_Flags & IS_NEW) == 0 )
return; return;
if (ItemFree) // no track in progress: switch layer only
{ // place micro via and switch layer
Other_Layer_Route(NULL, DC); if( GetScreen()->IsMicroViaAcceptable() )
break; {
} int v_type = g_DesignSettings.m_CurrentViaType;
if (GetCurItem()->Type() != TYPE_TRACK) g_DesignSettings.m_CurrentViaType = VIA_MICROVIA;
return; Other_Layer_Route( (TRACK*) GetCurItem(), DC );
if ((GetCurItem()->m_Flags & IS_NEW) == 0) g_DesignSettings.m_CurrentViaType = v_type;
return; if( DisplayOpt.ContrastModeDisplay )
Other_Layer_Route((TRACK*) GetCurItem(), DC); // place via and switch layer GetScreen()->SetRefreshReq();
if (DisplayOpt.ContrastModeDisplay) }
GetScreen()->SetRefreshReq(); break;
break;
case HK_ADD_VIA: // Switch to alternate layer and Place a via if a track is in progress
// Footprint edition: if( m_ID_current_state != ID_TRACK_BUTT )
case HK_LOCK_UNLOCK_FOOTPRINT: // toggle module "MODULE_is_LOCKED" status: return;
// get any module, locked or not locked and toggle its locked status if( ItemFree ) // no track in progress: switch layer only
if (ItemFree) {
module = Locate_Prefered_Module(GetBoard(), CURSEUR_OFF_GRILLE Other_Layer_Route( NULL, DC );
| VISIBLE_ONLY); break;
else if (GetCurItem()->Type() == TYPE_MODULE) }
module = (MODULE*) GetCurItem(); if( GetCurItem()->Type() != TYPE_TRACK )
if (module) { return;
SetCurItem(module); if( (GetCurItem()->m_Flags & IS_NEW) == 0 )
module->SetLocked(!module->IsLocked()); return;
module->DisplayInfo(this); Other_Layer_Route( (TRACK*) GetCurItem(), DC ); // place via and switch layer
} if( DisplayOpt.ContrastModeDisplay )
break; GetScreen()->SetRefreshReq();
break;
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
case HK_MOVE_FOOTPRINT: // Start move module // Footprint edition:
if (PopupOn) case HK_LOCK_UNLOCK_FOOTPRINT: // toggle module "MODULE_is_LOCKED" status:
break; // get any module, locked or not locked and toggle its locked status
if( ItemFree )
case HK_ROTATE_FOOTPRINT: // Rotation module = Locate_Prefered_Module( GetBoard(), CURSEUR_OFF_GRILLE
case HK_FLIP_FOOTPRINT: // move to other side | VISIBLE_ONLY );
int exit = 0; else if( GetCurItem()->Type() == TYPE_MODULE )
if (m_ID_current_state == ID_TRACK_BUTT) { module = (MODULE*) GetCurItem();
if (ItemFree) if( module )
DrawStruct = PcbGeneralLocateAndDisplay(); {
else SetCurItem( module );
DrawStruct = GetCurItem(); module->SetLocked( !module->IsLocked() );
module->DisplayInfo( this );
if (DrawStruct && (DrawStruct->Type() == TYPE_TRACK }
|| DrawStruct->Type() == TYPE_VIA)) break;
switch (HK_Descr->m_Idcommand) {
case HK_DRAG_FOOTPRINT: // Start move (and drag) module
case HK_DRAG_FOOTPRINT: // Start move (and drag) module case HK_MOVE_FOOTPRINT: // Start move module
DrawPanel->MouseToCursorSchema(); if( PopupOn )
//Start_DragTrackSegmentAndKeepSlope( (TRACK*) DrawStruct,DC ); break;
Start_MoveOneNodeOrSegment((TRACK*) DrawStruct, DC,
ID_POPUP_PCB_DRAG_TRACK_SEGMENT); case HK_ROTATE_FOOTPRINT: // Rotation
break; case HK_FLIP_FOOTPRINT: // move to other side
// fall through int exit = 0;
case HK_MOVE_FOOTPRINT: // Start move module if( m_ID_current_state == ID_TRACK_BUTT )
DrawPanel->MouseToCursorSchema(); {
Start_MoveOneNodeOrSegment((TRACK*) DrawStruct, DC, if( ItemFree )
ID_POPUP_PCB_MOVE_TRACK_NODE); DrawStruct = PcbGeneralLocateAndDisplay();
break; else
} DrawStruct = GetCurItem();
else
exit = 1; if( DrawStruct && (DrawStruct->Type() == TYPE_TRACK
|| DrawStruct->Type() == TYPE_VIA) )
} else if (!exit) { switch( HK_Descr->m_Idcommand )
{
if (ItemFree) { case HK_DRAG_FOOTPRINT: // Start move (and drag) module
module = Locate_Prefered_Module(GetBoard(), CURSEUR_OFF_GRILLE DrawPanel->MouseToCursorSchema();
| IGNORE_LOCKED | VISIBLE_ONLY
#if defined (USE_MATCH_LAYER) //Start_DragTrackSegmentAndKeepSlope( (TRACK*) DrawStruct,DC );
| MATCH_LAYER Start_MoveOneNodeOrSegment( (TRACK*) DrawStruct, DC,
ID_POPUP_PCB_DRAG_TRACK_SEGMENT );
break;
// fall through
case HK_MOVE_FOOTPRINT: // Start move module
DrawPanel->MouseToCursorSchema();
Start_MoveOneNodeOrSegment( (TRACK*) DrawStruct, DC,
ID_POPUP_PCB_MOVE_TRACK_NODE );
break;
}
else
exit = 1;
}
else if( !exit )
{
if( ItemFree )
{
module = Locate_Prefered_Module( GetBoard(), CURSEUR_OFF_GRILLE
| IGNORE_LOCKED | VISIBLE_ONLY
#if defined(USE_MATCH_LAYER)
| MATCH_LAYER
#endif #endif
); );
if (module == NULL) // no footprint found if( module == NULL ) // no footprint found
{ {
module = Locate_Prefered_Module(GetBoard(), module = Locate_Prefered_Module( GetBoard(),
CURSEUR_OFF_GRILLE | VISIBLE_ONLY); CURSEUR_OFF_GRILLE | VISIBLE_ONLY );
if (module) { if( module )
// a footprint is found, but locked or on an other layer {
if (module->IsLocked()) { // a footprint is found, but locked or on an other layer
wxString msg; if( module->IsLocked() )
{
msg.Printf(_("Footprint %s found, but locked"), wxString msg;
module->m_Reference->m_Text.GetData());
msg.Printf( _( "Footprint %s found, but locked" ),
DisplayInfoMessage(this, msg); module->m_Reference->m_Text.GetData() );
}
module = NULL; DisplayInfoMessage( this, msg );
} }
} module = NULL;
} else if (GetCurItem()->Type() == TYPE_MODULE) { }
module = (MODULE*) GetCurItem(); }
}
// @todo: might need to add a layer check in if() below else if( GetCurItem()->Type() == TYPE_MODULE )
if ((GetCurItem()->m_Flags == 0) && module->IsLocked()) {
module = NULL; // do not move, rotate ... it. module = (MODULE*) GetCurItem();
}
if (module == NULL) // @todo: might need to add a layer check in if() below
break; if( (GetCurItem()->m_Flags == 0) && module->IsLocked() )
module = NULL; // do not move, rotate ... it.
/* I'd like to make sending to EESCHEMA edge triggered, but the }
* simple mouse click on a module when the arrow icon is in play if( module == NULL )
* does not set GetCurItem() at this time, nor does a mouse click break;
* when the local ratsnest icon is in play set GetCurItem(), and these
* actions also call SendMessageToEESCHEMA(). /* I'd like to make sending to EESCHEMA edge triggered, but the
* if( GetCurItem() != module ) * simple mouse click on a module when the arrow icon is in play
*/ * does not set GetCurItem() at this time, nor does a mouse click
{ * when the local ratsnest icon is in play set GetCurItem(), and these
// Send the module via socket to EESCHEMA's search facility. * actions also call SendMessageToEESCHEMA().
SendMessageToEESCHEMA(module); * if( GetCurItem() != module )
*/
SetCurItem(module); {
} // Send the module via socket to EESCHEMA's search facility.
SendMessageToEESCHEMA( module );
switch (HK_Descr->m_Idcommand) {
case HK_ROTATE_FOOTPRINT: // Rotation SetCurItem( module );
Rotate_Module(DC, module, 900, TRUE); }
break;
switch( HK_Descr->m_Idcommand )
case HK_FLIP_FOOTPRINT: // move to other side {
Change_Side_Module(module, DC); case HK_ROTATE_FOOTPRINT: // Rotation
break; if( module->m_Flags == 0 ) // not currently in edit, prepare undo command
SaveCopyInUndoList( module, UR_ROTATED, module->m_Pos );
case HK_DRAG_FOOTPRINT: // Start move (and drag) module Rotate_Module( DC, module, 900, TRUE );
g_Drag_Pistes_On = TRUE; break;
// fall through case HK_FLIP_FOOTPRINT: // move to other side
case HK_MOVE_FOOTPRINT: // Start move module if( module->m_Flags == 0 ) // not currently in edit, prepare undo command
StartMove_Module(module, DC); SaveCopyInUndoList( module, UR_FLIPPED, module->m_Pos );
break; Change_Side_Module( module, DC );
} break;
module->DisplayInfo(this); case HK_DRAG_FOOTPRINT: // Start move (and drag) module
break; g_Drag_Pistes_On = TRUE;
}
} // fall through
case HK_MOVE_FOOTPRINT: // Start move module
StartMove_Module( module, DC );
break;
}
module->DisplayInfo( this );
break;
}
}
} }
/***********************************************************/ /***********************************************************/
void WinEDA_ModuleEditFrame::OnHotKey(wxDC* DC, int hotkey, void WinEDA_ModuleEditFrame::OnHotKey( wxDC* DC, int hotkey,
EDA_BaseStruct* DrawStruct) EDA_BaseStruct* DrawStruct )
/***********************************************************/ /***********************************************************/
/* Hot keys. Some commands are relative to the item under the mouse cursor /* Hot keys. Some commands are relative to the item under the mouse cursor
* Commands are case insensitive * Commands are case insensitive
*/ */
{ {
if (hotkey == 0) if( hotkey == 0 )
return; return;
wxCommandEvent cmd(wxEVT_COMMAND_MENU_SELECTED); wxCommandEvent cmd( wxEVT_COMMAND_MENU_SELECTED );
cmd.SetEventObject(this); cmd.SetEventObject( this );
/* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */ /* Convert lower to upper case (the usual toupper function has problem with non ascii codes like function keys */
if ((hotkey >= 'a') && (hotkey <= 'z')) if( (hotkey >= 'a') && (hotkey <= 'z') )
hotkey += 'A' - 'a'; hotkey += 'A' - 'a';
Ki_HotkeyInfo * HK_Descr = GetDescriptorFromHotkey(hotkey, Ki_HotkeyInfo* HK_Descr = GetDescriptorFromHotkey( hotkey,
s_Common_Hotkey_List); s_Common_Hotkey_List );
if (HK_Descr == NULL) if( HK_Descr == NULL )
HK_Descr = GetDescriptorFromHotkey(hotkey, s_module_edit_Hotkey_List); HK_Descr = GetDescriptorFromHotkey( hotkey, s_module_edit_Hotkey_List );
if (HK_Descr == NULL) if( HK_Descr == NULL )
return; return;
switch (HK_Descr->m_Idcommand) { switch( HK_Descr->m_Idcommand )
default: {
case HK_NOT_FOUND: default:
return; case HK_NOT_FOUND:
break; return;
break;
case HK_HELP: // Display Current hotkey list
DisplayHotkeyList(this, s_Module_Editor_Hokeys_Descr); case HK_HELP: // Display Current hotkey list
break; DisplayHotkeyList( this, s_Module_Editor_Hokeys_Descr );
break;
case HK_RESET_LOCAL_COORD: /*Reset the relative coord */
GetScreen()->m_O_Curseur = GetScreen()->m_Curseur; case HK_RESET_LOCAL_COORD: /*Reset the relative coord */
break; GetScreen()->m_O_Curseur = GetScreen()->m_Curseur;
break;
case HK_SWITCH_UNITS:
g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES; case HK_SWITCH_UNITS:
break; g_UnitMetric = (g_UnitMetric == INCHES) ? MILLIMETRE : INCHES;
break;
case HK_ZOOM_IN:
cmd.SetId(ID_POPUP_ZOOM_IN); case HK_ZOOM_IN:
GetEventHandler()->ProcessEvent(cmd); cmd.SetId( ID_POPUP_ZOOM_IN );
break; GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_OUT:
cmd.SetId(ID_POPUP_ZOOM_OUT); case HK_ZOOM_OUT:
GetEventHandler()->ProcessEvent(cmd); cmd.SetId( ID_POPUP_ZOOM_OUT );
break; GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_REDRAW:
cmd.SetId(ID_ZOOM_REDRAW); case HK_ZOOM_REDRAW:
GetEventHandler()->ProcessEvent(cmd); cmd.SetId( ID_ZOOM_REDRAW );
break; GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_CENTER:
cmd.SetId(ID_POPUP_ZOOM_CENTER); case HK_ZOOM_CENTER:
GetEventHandler()->ProcessEvent(cmd); cmd.SetId( ID_POPUP_ZOOM_CENTER );
break; GetEventHandler()->ProcessEvent( cmd );
break;
case HK_ZOOM_AUTO:
cmd.SetId(ID_ZOOM_PAGE); case HK_ZOOM_AUTO:
GetEventHandler()->ProcessEvent(cmd); cmd.SetId( ID_ZOOM_PAGE );
break; GetEventHandler()->ProcessEvent( cmd );
} break;
}
} }
/******************************************************************************/ /******************************************************************************/
bool WinEDA_PcbFrame::OnHotkeyDeleteItem(wxDC* DC, EDA_BaseStruct* DrawStruct) bool WinEDA_PcbFrame::OnHotkeyDeleteItem( wxDC* DC, EDA_BaseStruct* DrawStruct )
/******************************************************************************/ /******************************************************************************/
/* Delete the item foun under the mouse cursor /* Delete the item foun under the mouse cursor
...@@ -617,46 +691,51 @@ bool WinEDA_PcbFrame::OnHotkeyDeleteItem(wxDC* DC, EDA_BaseStruct* DrawStruct) ...@@ -617,46 +691,51 @@ bool WinEDA_PcbFrame::OnHotkeyDeleteItem(wxDC* DC, EDA_BaseStruct* DrawStruct)
* Delete the module. * Delete the module.
*/ */
{ {
bool ItemFree = (GetCurItem() == NULL) || (GetCurItem()->m_Flags == 0); bool ItemFree = (GetCurItem() == NULL) || (GetCurItem()->m_Flags == 0);
switch (m_ID_current_state) { switch( m_ID_current_state )
case ID_TRACK_BUTT: {
if (GetScreen()->m_Active_Layer > CMP_N) case ID_TRACK_BUTT:
return FALSE; if( GetScreen()->m_Active_Layer > CMP_N )
if (ItemFree) { return FALSE;
DrawStruct = PcbGeneralLocateAndDisplay(); if( ItemFree )
if (DrawStruct && DrawStruct->Type() != TYPE_TRACK) {
return FALSE; DrawStruct = PcbGeneralLocateAndDisplay();
Delete_Track(DC, (TRACK*) DrawStruct); if( DrawStruct && DrawStruct->Type() != TYPE_TRACK )
} else if (GetCurItem()->Type() == TYPE_TRACK) { return FALSE;
// simple lines for debugger: Delete_Track( DC, (TRACK*) DrawStruct );
TRACK* track = (TRACK*) GetCurItem(); }
track = Delete_Segment(DC, track); else if( GetCurItem()->Type() == TYPE_TRACK )
SetCurItem(track); {
GetScreen()->SetModify(); // simple lines for debugger:
return TRUE; TRACK* track = (TRACK*) GetCurItem();
} track = Delete_Segment( DC, track );
break; SetCurItem( track );
GetScreen()->SetModify();
case ID_COMPONENT_BUTT: return TRUE;
if (ItemFree) { }
MODULE* module = Locate_Prefered_Module(GetBoard(), break;
CURSEUR_ON_GRILLE);
if (module == NULL) case ID_COMPONENT_BUTT:
return FALSE; if( ItemFree )
if (!IsOK(this, _("Delete module?"))) {
return FALSE; MODULE* module = Locate_Prefered_Module( GetBoard(),
RemoveStruct(module, DC); CURSEUR_ON_GRILLE );
} else if( module == NULL )
return FALSE; return FALSE;
break; if( !IsOK( this, _( "Delete module?" ) ) )
return FALSE;
default: RemoveStruct( module, DC );
return FALSE; }
} else
return FALSE;
GetScreen()->SetModify(); break;
SetCurItem(NULL);
return TRUE; default:
return FALSE;
}
GetScreen()->SetModify();
SetCurItem( NULL );
return TRUE;
} }
...@@ -21,11 +21,11 @@ enum hotkey_id_commnand { ...@@ -21,11 +21,11 @@ enum hotkey_id_commnand {
HK_MOVE_FOOTPRINT, HK_MOVE_FOOTPRINT,
HK_DRAG_FOOTPRINT, HK_DRAG_FOOTPRINT,
HK_FLIP_FOOTPRINT, HK_FLIP_FOOTPRINT,
HK_GET_AND_MOVE_FOOTPRINT, HK_GET_AND_MOVE_FOOTPRINT,
HK_LOCK_UNLOCK_FOOTPRINT, HK_LOCK_UNLOCK_FOOTPRINT,
HK_ADD_VIA, HK_ADD_VIA,
HK_ADD_MICROVIA, HK_ADD_MICROVIA,
HK_END_TRACK, HK_END_TRACK,
HK_SAVE_BOARD, HK_LOAD_BOARD, HK_SAVE_BOARD, HK_LOAD_BOARD,
HK_SWITCH_UNITS, HK_SWITCH_UNITS,
HK_SWITCH_TRACK_DISPLAY_MODE, HK_SWITCH_TRACK_DISPLAY_MODE,
...@@ -56,9 +56,11 @@ enum hotkey_id_commnand { ...@@ -56,9 +56,11 @@ enum hotkey_id_commnand {
// List of hotkey descriptors for pcbnew // List of hotkey descriptors for pcbnew
extern struct Ki_HotkeyInfoSectionDescriptor s_Pcbnew_Editor_Hokeys_Descr[]; extern struct Ki_HotkeyInfoSectionDescriptor s_Pcbnew_Editor_Hokeys_Descr[];
// List of hotkey descriptors for the board editor only // List of hotkey descriptors for the board editor only
extern struct Ki_HotkeyInfoSectionDescriptor s_Board_Editor_Hokeys_Descr[]; extern struct Ki_HotkeyInfoSectionDescriptor s_Board_Editor_Hokeys_Descr[];
// List of hotkey descriptors for the footprint editor only // List of hotkey descriptors for the footprint editor only
extern struct Ki_HotkeyInfoSectionDescriptor s_Module_Editor_Hokeys_Descr[]; extern struct Ki_HotkeyInfoSectionDescriptor s_Module_Editor_Hokeys_Descr[];
#endif // KOTKEYS_H #endif // KOTKEYS_H
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment