Add Altium Delphi scripts
authorHugo Villeneuve <hugo@hugovil.com>
Wed, 18 Dec 2013 15:50:01 +0000 (10:50 -0500)
committerHugo Villeneuve <hugo@hugovil.com>
Fri, 24 Jan 2014 03:54:32 +0000 (22:54 -0500)
scripts/altium/cleanlib.pas [new file with mode: 0644]
scripts/altium/functions.pas [new file with mode: 0644]
scripts/altium/pcb-assembly-drawings.pas [new file with mode: 0644]
scripts/altium/pcb-lit-de-clou.pas [new file with mode: 0644]
scripts/altium/pcb-resize-refdes-all.pas [new file with mode: 0644]
scripts/altium/pcb-resize-refdes-selection.pas [new file with mode: 0644]
scripts/altium/sch-align-refdes-all.pas [new file with mode: 0644]
scripts/altium/sch-align-refdes-selection.pas [new file with mode: 0644]
scripts/altium/sch-align-refdes.pas [new file with mode: 0644]
scripts/altium/scripts.PrjScr [new file with mode: 0644]

diff --git a/scripts/altium/cleanlib.pas b/scripts/altium/cleanlib.pas
new file mode 100644 (file)
index 0000000..075b240
--- /dev/null
@@ -0,0 +1,148 @@
+// Standardisation du nom des paramètres des composants d'une librairie\r
+\r
+Procedure CleanLibrary;\r
+Var\r
+   CurrentLib      : ISch_Lib;\r
+   LibraryIterator : ISch_Iterator;\r
+   LibComp         : ISch_Component;\r
+   PIterator       : ISch_Iterator;\r
+   Parameter       : ISch_Parameter;\r
+   \r
+   RefPrefix         : String;\r
+   ImplIterator      : ISch_Iterator;\r
+   SchImplementation : ISch_Implementation;\r
+   \r
+Begin\r
+   If SchServer = Nil Then Exit;\r
+   CurrentLib := SchServer.GetCurrentSchDocument;\r
+   If CurrentLib = Nil Then Exit;\r
+\r
+   // check if the document is a schematic library\r
+   If CurrentLib.ObjectID <> eSchLib Then\r
+   Begin\r
+      ShowError('Please open schematic library.');\r
+      Exit;\r
+   End;\r
+\r
+   // create a library iterator to look for\r
+   // symbols in the currently focussed library.\r
+   LibraryIterator := CurrentLib.SchLibIterator_Create;\r
+   LibraryIterator.AddFilter_ObjectSet(MkSet(eSchComponent));\r
+   Try\r
+      // obtain the first symbol in the library\r
+      LibComp := LibraryIterator.FirstSchObject;\r
+      While LibComp <> Nil Do\r
+      Begin\r
+         \r
+         RefPrefix := Copy(UpperCase(LibComp.Designator.Text), 1, 1);\r
+         \r
+         // Corrections champs description\r
+         If UpperCase(LibComp.ComponentDescription) = 'RESISTOR FIXE' Then\r
+            LibComp.ComponentDescription := 'Resistor';\r
+         If UpperCase(LibComp.ComponentDescription) = 'CAPACITOR CERAMIQUE COG' Then\r
+            LibComp.ComponentDescription := 'Capacitor Ceramic C0G';\r
+         If UpperCase(LibComp.ComponentDescription) = 'CAPACITOR CERAMIQUE NPO' Then\r
+            LibComp.ComponentDescription := 'Capacitor Ceramic NP0';\r
+         If UpperCase(LibComp.ComponentDescription) = 'CAPACITOR CERAMIQUE X5R' Then\r
+            LibComp.ComponentDescription := 'Capacitor Ceramic X5R';\r
+         If UpperCase(LibComp.ComponentDescription) = 'CAPACITOR CERAMIQUE X7R' Then\r
+            LibComp.ComponentDescription := 'Capacitor Ceramic X7R';\r
+         If UpperCase(LibComp.ComponentDescription) = 'CAPACITOR CERAMIQUE S-SERIE' Then\r
+            LibComp.ComponentDescription := 'Capacitor Ceramic NP0';\r
+\r
+         // look for parameters associated with this symbol in a library.\r
+         Try\r
+            PIterator := LibComp.SchIterator_Create;\r
+            PIterator.AddFilter_ObjectSet(MkSet(eParameter));\r
+\r
+            Parameter := PIterator.FirstSchObject;\r
+            While Parameter <> Nil Do\r
+            Begin\r
+               If CompareString(UpperCase(Parameter.Name), 'MANUFACTURIER', 13) Then\r
+                  Parameter.Name := 'Manufacturer';\r
+               \r
+               If CompareString(UpperCase(Parameter.Name), 'MANUFACTURER', 12) Then\r
+               Begin\r
+                  Parameter.Text := UpperCase(Parameter.Text); // Conversion majuscules\r
+                  \r
+                  If CompareString(Parameter.Text, 'CAL CHIP', 8) Or\r
+                        CompareString(Parameter.Text, 'CAL-CHIP', 8) Or\r
+                        CompareString(Parameter.Text, 'CAL_CHIP', 8) Or\r
+                        CompareString(Parameter.Text, 'CALCHIP', 7) Then\r
+                     Parameter.Text := 'CAL-CHIP';\r
+                  \r
+                  If CompareString(Parameter.Text, 'ON SEMI', 7) Or\r
+                        CompareString(Parameter.Text, 'ONSEMI', 6) Then\r
+                     Parameter.Text := 'ON SEMICONDUCTOR';\r
+                  \r
+                  If CompareString(Parameter.Text, 'TEXAS', 5) Or\r
+                        CompareString(Parameter.Text, 'TI', 2) Then\r
+                     Parameter.Text := 'TEXAS INSTRUMENTS';\r
+                  \r
+                  If CompareString(Parameter.Text, 'ANALOG DEVICE', 13) Then\r
+                     Parameter.Text := 'ANALOG DEVICES';\r
+\r
+                  If CompareString(Parameter.Text, 'VISHAY', 6) Then\r
+                     Parameter.Text := 'VISHAY';\r
+               End;\r
+               \r
+               If CompareString(UpperCase(Parameter.Name), 'PUISSANCE', 9) Then\r
+                  Parameter.Name := 'Power';\r
+               \r
+               If CompareString(UpperCase(Parameter.Name), 'NO MANUF', 8) Then\r
+                  Parameter.Name := 'MPN';\r
+               \r
+               If CompareString(UpperCase(Parameter.Name), 'TOL', 3) Then\r
+                  Parameter.Name := 'Tolerance';\r
+               \r
+               ImplIterator := LibComp.SchIterator_Create;\r
+               ImplIterator.AddFilter_ObjectSet(MkSet(eImplementation));\r
+               SchImplementation := ImplIterator.FirstSchObject;\r
+               While SchImplementation <> Nil Do\r
+               Begin\r
+                  If StringsEqual(SchImplementation.ModelType, 'PCBLIB') Then\r
+                  Begin\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '1206-016', 8) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_1206_016';\r
+                     \r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '0402', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_0402';\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '0603', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_0603';\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '0805', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_0805';\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '1206', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_1206';\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '1210', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_1210';\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '1812', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_1812';\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '2010', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_2010';\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), '2225', 4) Then\r
+                        SchImplementation.ModelName := RefPrefix + '_2225';\r
+                     \r
+                     // Remove duplicates\r
+                     If CompareString(UpperCase(SchImplementation.ModelName), RefPrefix + '_0402', 6) And Not SchImplementation.IsCurrent Then\r
+                        LibComp.RemoveSchObject(SchImplementation);\r
+                     \r
+                  End;\r
+                  SchImplementation := ImplIterator.NextSchObject;\r
+               End;\r
+               LibComp.SchIterator_Destroy(ImplIterator);\r
+\r
+               Parameter := PIterator.NextSchObject;\r
+            End;\r
+         Finally\r
+            LibComp.SchIterator_Destroy(PIterator);\r
+         End;\r
+         // obtain the next symbol in the library\r
+         LibComp := LibraryIterator.NextSchObject;\r
+      End;\r
+   Finally\r
+      // done with looking for symbols and parameters.\r
+      // destroy the library iterator.\r
+      CurrentLib.SchIterator_Destroy(LibraryIterator);\r
+   End;\r
+\r
+End;\r
diff --git a/scripts/altium/functions.pas b/scripts/altium/functions.pas
new file mode 100644 (file)
index 0000000..c72dbfd
--- /dev/null
@@ -0,0 +1,180 @@
+Const
+    MY_BOX_WIDTH_MILS = 4;
+    MY_CIRCLE_WIDTH_MILS = 4;
+
+    MY_REF_SIZE_MILS  = 30;
+    MY_REF_WIDTH_MILS = 4;
+
+Var
+    MinX, MinY, MaxX, MaxY : Integer;
+
+Procedure RemoveSpaces(Var Str : AnsiString);
+Var
+    SpacePos : Integer;
+Begin
+    Repeat
+        SpacePos := Pos(' ', Str);
+        If SpacePos <> 0 Then
+            Delete(Str, SpacePos, 1);
+    Until SpacePos = 0;
+End;
+
+Function IsNumber(AChar : Char) : Boolean;
+Begin
+    Result := ('0' <= AChar) And (AChar <= '9');
+End;
+
+Function IsLetter(AChar : Char) : Boolean;
+Begin
+    Result := ('a' <= AChar) And (AChar <= 'Z');
+End;
+
+Function CompareString(a, b : AnsiString; len : Integer) : Boolean;
+Var
+    a1, b1 : AnsiString;
+Begin
+    Result := False;
+
+    a1 := Copy(a, 1, len);
+    b1 := Copy(b, 1, len);
+
+    Result := a1 = b1;
+End;
+
+
+Procedure ClearAssemblyLayer(Board : IPCB_Board; Layer :  TLayer);
+Var
+    Comp      : IPCB_Component;
+    Iterator  : IPCB_BoardIterator;
+Begin
+    // Setup Board iterator 
+    Iterator        := Board.BoardIterator_Create; 
+    Iterator.AddFilter_ObjectSet(AllObjects); 
+    Iterator.AddFilter_LayerSet(MkSet(Layer));
+    Iterator.AddFilter_Method(eProcessAll);
+    
+    Comp := Iterator.FirstPCBObject;
+    While (Comp <> Nil) Do
+    Begin
+        Board.RemovePCBObject(Comp);
+
+        Comp := Iterator.NextPCBObject;
+    End;
+    
+    Board.BoardIterator_Destroy(Iterator);
+End;
+
+
+Procedure TrackAdd(Board : IPCB_Board; Layer : TLayer; x1, y1, x2, y2 : Integer);
+Var
+    Track : IPCB_Track;
+Begin
+    // Create a Track object.
+    Track := PCBServer.PCBObjectFactory(eTrackObject, eNoDimension, eCreate_Default);
+
+    Track.X1       := x1;
+    Track.Y1       := y1;
+    Track.X2       := x2;
+    Track.Y2       := y2;
+    Track.Layer    := Layer;
+    Track.Width    := MilsToCoord(MY_BOX_WIDTH_MILS);
+    Board.AddPCBObject(Track);
+End;
+
+
+Procedure CreateBondingBox(Board : IPCB_Board; Layer : TLayer);
+Begin
+    TrackAdd(Board, Layer, MinX, MinY, MaxX, MinY);
+    TrackAdd(Board, Layer, MaxX, MinY, MaxX, MaxY);
+    TrackAdd(Board, Layer, MaxX, MaxY, MinX, MaxY);
+    TrackAdd(Board, Layer, MinX, MaxY, MinX, MinY);
+End;
+
+
+Procedure CreateBondingCircle(Board : IPCB_Board; Layer : TLayer; x, y, r : Integer);
+Var
+    Arc : IPCB_Arc;
+Begin
+    Arc := PCBServer.PCBObjectFactory(eArcObject, eNoDimension, eCreate_Default);
+    Arc.XCenter    := x;
+    Arc.YCenter    := y;
+    Arc.Radius     := r;
+    Arc.LineWidth  := MilsToCoord(MY_CIRCLE_WIDTH_MILS);
+    Arc.StartAngle := 0;
+    Arc.EndAngle   := 360;
+    Arc.Layer      := Layer;
+    Board.AddPCBObject(Arc);
+End;
+
+
+Procedure ProcessObjectsOfAComponent(Const P : IPCB_Primitive);
+Var
+    R : TCoordRect;
+Begin
+    // check for comment / name objects
+    If P.ObjectId <> eTextObject Then
+    Begin
+        R := P.BoundingRectangle;
+
+        If R.left   < MinX Then MinX := R.left;
+        If R.bottom < MinY Then MinY := R.bottom;
+        If R.right  > MaxX Then MaxX := R.right;
+        If R.top    > MaxY Then MaxY := R.top;
+    End;
+End;
+
+Procedure FetchComponentMidPoints(Comp : IPCB_Component; out MidX, MidY, MaxLen, MaxHeight);
+Var
+    GroupIterator : IPCB_GroupIterator;
+    GroupHandle   : IPCB_Primitive;
+Begin
+    // setting extreme constants...
+    MinX :=  2147483647;
+    MinY :=  2147483647;
+    MaxX := -2147483647;
+    MaxY := -2147483647;
+
+    GroupIterator := Comp.GroupIterator_Create;
+    GroupIterator.AddFilter_ObjectSet(AllObjects);
+    GroupHandle   := GroupIterator.FirstPCBObject;
+    While GroupHandle <> Nil Do
+    Begin
+        ProcessObjectsOfAComponent(GroupHandle);
+        GroupHandle := GroupIterator.NextPCBObject;
+    End;
+    Comp.GroupIterator_Destroy(GroupIterator);
+
+    MidX := (MinX + MaxX) / 2;
+    MidY := (MinY + MaxY) / 2;
+    
+    Case Comp.Name.Rotation of
+        0   : MaxLen := MaxX - MinX;
+        90  : MaxLen := MaxY - MinY;
+        270 : MaxLen := MaxY - MinY;
+    End;
+    
+    Case Comp.Name.Rotation of
+        0   : MaxHeight := MaxY - MinY;
+        90  : MaxHeight := MaxX - MinX;
+        270 : MaxHeight := MaxX - MinX;
+    End;
+End;
+
+Procedure ResizeRefDes(Comp : IPCB_Component);
+Begin
+   // Check if Component Name property exists before extracting the text
+   If Comp.Name = Nil Then Exit;
+
+   // Modify the component
+   PCBServer.SendMessageToRobots(Comp.I_ObjectAddress, c_Broadcast, PCBM_BeginModify , c_NoEventData);
+
+   Comp.Name.Size  := MilsToCoord(MY_REF_SIZE_MILS);;
+   Comp.Name.Width := MilsToCoord(MY_REF_WIDTH_MILS);
+   Comp.Name.UseTTFonts := False; 
+   Comp.Name.Italic := False; 
+   Comp.Name.Bold := False; 
+   Comp.Name.FontName := 'Default';
+
+   PCBServer.SendMessageToRobots(Comp.I_ObjectAddress, c_Broadcast, PCBM_EndModify , c_NoEventData);
+End;
+
diff --git a/scripts/altium/pcb-assembly-drawings.pas b/scripts/altium/pcb-assembly-drawings.pas
new file mode 100644 (file)
index 0000000..b5b3a45
--- /dev/null
@@ -0,0 +1,262 @@
+// Création des dessins d'assemblage sur les couches mécaniques 10 (TOP) et 11 (BOT)\r
+//\r
+// TODO:\r
+//   Afficher le nombre de composants total et celui qui est présentement traité (1/200)\r
+//   Gérer les composants avec des orientations non multiples de 90 deg.\r
+\r
+Const\r
+    MY_REF_SIZE_MILS  = 30;\r
+    MY_REF_WIDTH_MILS = 3;\r
+    \r
+    // La grosseur du texte en fonction de la taille du composant, jusqu´à cette limite.\r
+    TEXT_SIZE_MAX_MILS = 100;\r
+     \r
+    // Ratio de la longueur du texte du refdes par rapport à la longueur maximale permise par les dimensions du composant.\r
+    RATIO_MAXLEN_REFDES = 0.85;\r
+\r
+    // Ratio de la hauteur du texte du refdes par rapport à la hauteur maximale permise par les dimensions du composant.    \r
+    RATIO_MAXHEIGHT_REFDES = 0.65;\r
+    \r
+    // Ajustement empirique.\r
+    AJUSTEMENT_CENTRAGE = 0.90;\r
+    \r
+    TOP_ASSEMBLY_LAYER = eMechanical10;\r
+    BOT_ASSEMBLY_LAYER = eMechanical11;\r
+\r
+Procedure PCB_GenerateAssemblyDrawings;\r
+Var\r
+    Board     : IPCB_Board;\r
+    Comp      : IPCB_Component;\r
+    Iterator  : IPCB_BoardIterator;\r
+\r
+    strlen,   : Integer;\r
+    StrWidth  : TCoord;\r
+    StrHeight : TCoord;\r
+    OffsetX :   TCoord;\r
+    OffsetY :   TCoord;\r
+    MidX, MidY : Integer;\r
+    MaxLen     : Integer;\r
+    MaxHeight  : Integer;\r
+    TempSize : Integer;\r
+    \r
+    IsCircle : Boolean;\r
+    \r
+    DestLayer : TLayer;\r
+    TextObj : IPCB_Text;\r
+    \r
+    // Pour sauvegarder les valeurs du composant original.\r
+    OldCommentOn : Boolean;\r
+    OldCompRotation : Integer;\r
+    OldCompNameRotation : Integer;\r
+    \r
+    // Attributs du nouveau composant sur la couche d'assemblage\r
+    NewRotation  : Integer;\r
+    NewSize      : Integer;\r
+    \r
+Begin\r
+    Pcbserver.PreProcess;\r
+\r
+    Board := PCBServer.GetCurrentPCBBoard;\r
+    If Not Assigned(Board) Then\r
+    Begin\r
+        ShowMessage('The Current Document is not a Protel PCB Document.');\r
+        Exit;\r
+    End;\r
+    \r
+    // Efface les 2 couches d'assemblage\r
+    ClearAssemblyLayer(Board, TOP_ASSEMBLY_LAYER);\r
+    ClearAssemblyLayer(Board, BOT_ASSEMBLY_LAYER);\r
+    \r
+    // Setup Board iterator\r
+    Iterator        := Board.BoardIterator_Create; \r
+    Iterator.AddFilter_ObjectSet(MkSet(eComponentObject)); \r
+    //Iterator.AddFilter_LayerSet(MkSet(eBottomLayer));\r
+    Iterator.AddFilter_LayerSet(AllLayers); \r
+    Iterator.AddFilter_Method(eProcessAll);\r
+    \r
+    Comp := Iterator.FirstPCBObject;\r
+    While (Comp <> Nil) Do\r
+    Begin\r
+        IsCircle := False;\r
+        \r
+        // Check if Component Name property exists before extracting the text\r
+        If Comp.Name = Nil Then Exit;\r
+\r
+        // On ne modifie pas le numéro du PCB, qui est la référence du logo de compagnie\r
+        If CompareString(Comp.Pattern, 'LOGOCOMPANY', 7) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        If CompareString(UpperCase(Comp.Pattern), 'MIRE', 4) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        If CompareString(UpperCase(Comp.Pattern), 'CRACK', 5) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        // On n´affiche pas les fiducials\r
+        If CompareString(UpperCase(Comp.Pattern), 'FIDG', 4) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        // On n´affiche pas la légende des couches\r
+        If CompareString(UpperCase(Comp.Pattern), 'LAYERS', 6) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        // Modify the component\r
+        PCBServer.SendMessageToRobots(Comp.I_ObjectAddress, c_Broadcast, PCBM_BeginModify , c_NoEventData);\r
+\r
+        // Sauvegarde valeurs originales\r
+        OldCommentOn := Comp.CommentOn;\r
+        OldCompRotation := Comp.Rotation;\r
+        OldCompNameRotation := Comp.Name.Rotation;\r
+\r
+        // Sauf pour les MH\r
+        if CompareString(Comp.Name.Text, 'MH', 2) Then\r
+            IsCircle := True;\r
+         if CompareString(Comp.Name.Text, 'TP', 2) Then\r
+            IsCircle := True;\r
+            \r
+        If IsCircle Then\r
+            Comp.Rotation := 0;\r
+\r
+        // Et on désactive temporairement les commentaires\r
+        Comp.CommentOn := False;\r
+        \r
+        // On fait une rotation de la référence selon l'orientation du composant\r
+        Case Comp.Rotation of\r
+            0, 180, 360 : Comp.Name.Rotation := 0;\r
+            90, 270 : Comp.Name.Rotation := 90;\r
+        End;\r
+\r
+        If Comp.Layer = eBottomLayer Then\r
+        Begin\r
+            Case Comp.Name.Rotation of\r
+                90   : Comp.Name.Rotation := 270;\r
+            End;\r
+        End;\r
+\r
+        FetchComponentMidPoints(Comp, MidX, MidY, MaxLen, MaxHeight);\r
+        \r
+        // string length * character_width <= MaxLen\r
+        // character_width = 2/3 * Size en mil.\r
+        //   Ex: Si le size est de 30 mils, la largeur est environ de 20 mils.\r
+        // -> Size = MaxLen / strlen * 3/2 \r
+        strlen := Length(Comp.Name.Text);\r
+\r
+        // Calcul de la grosseur de la référence selon la longueur disponible (bonding box).\r
+        TempSize := CoordToMils(MaxLen * RATIO_MAXLEN_REFDES) / strlen * 0.9;\r
+        if TempSize > TEXT_SIZE_MAX_MILS Then\r
+            TempSize := TEXT_SIZE_MAX_MILS;\r
+        \r
+        // Ajustement selon la hauteur disponible (bonding box).\r
+        If TempSize > (CoordToMils(MaxHeight) * RATIO_MAXHEIGHT_REFDES) Then\r
+            TempSize := CoordToMils(MaxHeight) * RATIO_MAXHEIGHT_REFDES;\r
+\r
+        // Adjust size according to available space\r
+        NewSize  := MilsToCoord(TempSize);\r
+        StrWidth := strlen * NewSize;\r
+        StrHeight:= NewSize;\r
+\r
+        If Comp.Layer = eTopLayer Then\r
+        Begin\r
+            DestLayer := TOP_ASSEMBLY_LAYER;\r
+            Case Comp.Name.Rotation of\r
+                0   :\r
+                    Begin\r
+                        OffsetX := -StrWidth  / 2;\r
+                        OffsetY := -StrHeight / 2;\r
+                    End;\r
+                90  :\r
+                    Begin\r
+                        OffsetX := StrHeight / 2;\r
+                        OffsetY := -StrWidth  / 2;\r
+                    End;\r
+            End;\r
+        End;\r
+        If Comp.Layer = eBottomLayer Then\r
+        Begin\r
+            DestLayer := BOT_ASSEMBLY_LAYER;\r
+            Case Comp.Name.Rotation of\r
+                0  :\r
+                    Begin\r
+                        OffsetX :=  StrWidth  / 2;\r
+                        OffsetY := -StrHeight / 2;\r
+                    End;\r
+                270 :\r
+                    Begin\r
+                        OffsetX := -StrHeight / 2;\r
+                        OffsetY := -StrWidth  / 2;\r
+                    End;\r
+            End;\r
+        End;\r
+        \r
+        // Ajustement empirique...    \r
+        Case Comp.Name.Rotation of\r
+            0   : OffsetX := OffsetX * AJUSTEMENT_CENTRAGE;\r
+            90  : OffsetY := OffsetY * AJUSTEMENT_CENTRAGE;\r
+            270 : OffsetY := OffsetY * AJUSTEMENT_CENTRAGE;\r
+        End;\r
+\r
+        // Sauvegarde nouvelles valeurs pour nouveau composant sur couche d'assemblage\r
+        NewRotation  := Comp.Name.Rotation;\r
+\r
+        // Restauration valeurs originales\r
+        Comp.CommentOn := OldCommentOn;\r
+        Comp.Rotation := OldCompRotation;\r
+        Comp.Name.Rotation := OldCompNameRotation;\r
+\r
+        PCBServer.SendMessageToRobots(Comp.I_ObjectAddress, c_Broadcast, PCBM_EndModify , c_NoEventData);\r
+        \r
+        If IsCircle Then\r
+            // Crée un cercle représentant le composant\r
+            CreateBondingcircle(Board, DestLayer, MidX, MidY, MaxLen / 2)\r
+        Else\r
+            // Crée une boite représentant le composant\r
+            CreateBondingBox(Board, DestLayer);\r
+        \r
+        //Create a first text object non True Type font.\r
+        TextObj := PCBServer.PCBObjectFactory(eTextObject, eNoDimension, eCreate_Default);\r
+\r
+        // notify that the pcb object is going to be modified\r
+        PCBServer.SendMessageToRobots(TextObj.I_ObjectAddress ,c_Broadcast, PCBM_BeginModify , c_NoEventData);\r
+\r
+        TextObj.Layer     := DestLayer;\r
+        TextObj.XLocation := MidX + OffsetX;\r
+        TextObj.YLocation := MidY + OffsetY;\r
+        TextObj.Rotation  := NewRotation;\r
+        TextObj.Text      := Comp.Name.Text;\r
+        TextObj.Size  := NewSize;\r
+        TextObj.Width := MilsToCoord(MY_REF_WIDTH_MILS);\r
+        TextObj.UseTTFonts := False; \r
+        TextObj.Italic := False; \r
+        TextObj.Bold := False; \r
+        TextObj.FontName := 'Default';\r
+        If Comp.Layer = eBottomLayer Then\r
+            TextObj.MirrorFlag := True;\r
+\r
+        Board.AddPCBObject(TextObj);\r
+\r
+        // notify that the pcb object has been modified\r
+        PCBServer.SendMessageToRobots(TextObj.I_ObjectAddress, c_Broadcast, PCBM_EndModify         , c_NoEventData);\r
+       \r
+        Comp := Iterator.NextPCBObject;\r
+    End;\r
+    \r
+    Board.BoardIterator_Destroy(Iterator);\r
+    \r
+    Pcbserver.PostProcess;\r
+    Client.SendMessage('PCB:Zoom', 'Action=Redraw', 255, Client.CurrentView);\r
+End;\r
diff --git a/scripts/altium/pcb-lit-de-clou.pas b/scripts/altium/pcb-lit-de-clou.pas
new file mode 100644 (file)
index 0000000..b54438c
--- /dev/null
@@ -0,0 +1,212 @@
+// Création d´un dessin pour lit de clou. Efface toutes les références\r
+// sauf pour les JP et MP\r
+\r
+Const\r
+    MY_REF_SIZE_MILS  = 30;\r
+    MY_REF_WIDTH_MILS = 2;\r
+    \r
+    // La grosseur du texte en fonction de la taille du composant, jusqu´à cette limite.\r
+    TEXT_SIZE_MAX_MILS = 100;\r
+     \r
+    // Ratio de la longueur du texte du refdes par rapport à la longueur maximale permise par les dimensions du composant.\r
+    RATIO_MAXLEN_REFDES = 0.85;\r
+    \r
+    // Ajustement empirique.\r
+    AJUSTEMENT_CENTRAGE = 0.90;\r
+   \r
+Procedure PCB_CreationDessinLitDeClou;\r
+Var\r
+    Board     : IPCB_Board;\r
+    Comp      : IPCB_Component;\r
+    Iterator  : IPCB_BoardIterator;\r
+\r
+    strlen,   : Integer;\r
+    StrWidth  : TCoord;\r
+    StrHeight : TCoord;\r
+    OffsetX :   TCoord;\r
+    OffsetY :   TCoord;\r
+    MidX, MidY : Integer;\r
+    MaxLen     :     Integer;\r
+    TempSize : Integer;\r
+    \r
+    Valide   : Boolean;\r
+Begin\r
+    Pcbserver.PreProcess;\r
+\r
+    Board := PCBServer.GetCurrentPCBBoard;\r
+    If Not Assigned(Board) Then\r
+    Begin\r
+        ShowMessage('The Current Document is not a Protel PCB Document.');\r
+        Exit;\r
+    End;\r
+        \r
+    // Setup Board iterator \r
+    Iterator        := Board.BoardIterator_Create; \r
+    Iterator.AddFilter_ObjectSet(MkSet(eComponentObject)); \r
+    //Iterator.AddFilter_LayerSet(MkSet(eTopLayer));\r
+    Iterator.AddFilter_LayerSet(AllLayers); \r
+    Iterator.AddFilter_Method(eProcessAll);\r
+    \r
+    Comp := Iterator.FirstPCBObject;\r
+    While (Comp <> Nil) Do\r
+    Begin\r
+        // Check if Component Name property exists before extracting the text\r
+        If Comp.Name = Nil Then Exit;\r
+\r
+        /////ShowMessage('Processing component ' + Comp.Name.Text);\r
+\r
+        // Modify the component\r
+        PCBServer.SendMessageToRobots(Comp.I_ObjectAddress, c_Broadcast, PCBM_BeginModify , c_NoEventData);\r
+\r
+        Valide := False;\r
+\r
+        // On n´affiche pas la référence...\r
+        Comp.NameOn := False;\r
+        \r
+        // ..sauf pour ces composants:\r
+        If CompareString(Comp.Name.Text, 'MP', 2) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPA', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPB', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPD', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPE', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPF', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPG', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPH', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPI', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPJ', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPK', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPL', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPM', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPN', 3) Then\r
+            Valide := True;\r
+        If CompareString(Comp.Name.Text, 'JPP', 3) Then\r
+            Valide := True;\r
+\r
+                    \r
+        If NOT Valide Then\r
+        Begin\r
+            Board.RemovePCBObject(Comp);\r
+            Comp := Iterator.NextPCBObject;\r
+            Continue;\r
+        End\r
+        Else\r
+        Begin\r
+            Comp.NameOn := True;\r
+        End;\r
+\r
+        // Et on élimine les commentaires\r
+        Comp.CommentOn := False;\r
+\r
+        // On fait une rotation de la référence selon l´orientation du composant\r
+        // sauf pour les MP qui sont ronds\r
+        If CompareString(Comp.Name.Text, 'MP', 2) Then\r
+        Begin\r
+            Comp.Name.Rotation := 0;\r
+        End\r
+        Else\r
+        Begin\r
+            Case Comp.Rotation of\r
+                0    : Comp.Name.Rotation := 0;\r
+                180  : Comp.Name.Rotation := 0;\r
+                360  : Comp.Name.Rotation := 0;\r
+                90   : Comp.Name.Rotation := 90;\r
+                270  : Comp.Name.Rotation := 90;\r
+            End;\r
+            \r
+            If Comp.Layer = eBottomLayer Then\r
+            Begin\r
+                Case Comp.Name.Rotation of\r
+                    90   : Comp.Name.Rotation := 270;\r
+                End;\r
+            End;\r
+        End;\r
+\r
+        FetchComponentMidPoints(Comp, MidX, MidY, MaxLen);\r
+        \r
+        // string length * character_width <= MaxLen\r
+        // character_width = 2/3 * Size en mil.\r
+        //   Ex: Si le size est de 30 mils, la largeur est environ de 20 mils.\r
+        // -> Size = MaxLen / strlen * 3/2 \r
+        strlen := Length(Comp.Name.Text);\r
+\r
+        // Adjust size\r
+        Comp.Name.UseTTFonts := False; \r
+        Comp.Name.Italic := False; \r
+        Comp.Name.Bold := False; \r
+        Comp.Name.FontName := 'Default';\r
+        \r
+        TempSize := CoordToMils(MaxLen * RATIO_MAXLEN_REFDES) / strlen * 0.9;\r
+        if TempSize > TEXT_SIZE_MAX_MILS Then\r
+            TempSize := TEXT_SIZE_MAX_MILS;\r
+        \r
+        Comp.Name.Size  := MilsToCoord(TempSize);\r
+        Comp.Name.Width := MilsToCoord(MY_REF_WIDTH_MILS);\r
+\r
+        StrWidth := strlen * Comp.Name.Size;\r
+        StrHeight:= Comp.Name.Size;\r
+\r
+        If Comp.Layer = eTopLayer Then\r
+        Begin\r
+            Case Comp.Name.Rotation of\r
+                0   :\r
+                    Begin\r
+                        OffsetX := -StrWidth  / 2;\r
+                        OffsetY := -StrHeight / 2;\r
+                    End;\r
+                90  :\r
+                    Begin\r
+                        OffsetX := StrHeight / 2;\r
+                        OffsetY := -StrWidth  / 2;\r
+                    End;\r
+            End;\r
+        End;\r
+        If Comp.Layer = eBottomLayer Then\r
+        Begin\r
+            Case Comp.Name.Rotation of\r
+                0  :\r
+                    Begin\r
+                        OffsetX := StrWidth  / 2;\r
+                        OffsetY := -StrHeight / 2;\r
+                    End;\r
+                270 :\r
+                    Begin\r
+                        OffsetX := -StrHeight / 2;\r
+                        OffsetY := -StrWidth  / 2;\r
+                    End;\r
+            End;\r
+        End;\r
+        \r
+        // Ajustement empirique...    \r
+        Case Comp.Name.Rotation of\r
+            0   : OffsetX := OffsetX * AJUSTEMENT_CENTRAGE;\r
+            90  : OffsetY := OffsetY * AJUSTEMENT_CENTRAGE;\r
+            270 : OffsetY := OffsetY * AJUSTEMENT_CENTRAGE;\r
+        End;\r
+\r
+        Comp.Name.XLocation := MidX + OffsetX;\r
+        Comp.Name.YLocation := MidY + OffsetY;\r
+\r
+        PCBServer.SendMessageToRobots(Comp.I_ObjectAddress, c_Broadcast, PCBM_EndModify , c_NoEventData);\r
+        //Client.SendMessage('PCB:Zoom', 'Action=Redraw', 255, Client.CurrentView);\r
+\r
+        Comp := Iterator.NextPCBObject;\r
+    End;\r
+    \r
+    Board.BoardIterator_Destroy(Iterator);\r
+    \r
+    Pcbserver.PostProcess;\r
+    Client.SendMessage('PCB:Zoom', 'Action=Redraw', 255, Client.CurrentView);\r
+End;\r
diff --git a/scripts/altium/pcb-resize-refdes-all.pas b/scripts/altium/pcb-resize-refdes-all.pas
new file mode 100644 (file)
index 0000000..6e40326
--- /dev/null
@@ -0,0 +1,71 @@
+// Redimensionnement du texte des références de tous les composants\r
+\r
+Procedure PCB_ResizeRefDes_All;\r
+Var\r
+    Board     : IPCB_Board;\r
+    Comp      : IPCB_Component;\r
+    Iterator  : IPCB_BoardIterator;\r
+\r
+Begin\r
+    Pcbserver.PreProcess;\r
+\r
+    Board := PCBServer.GetCurrentPCBBoard;\r
+    If Not Assigned(Board) Then\r
+    Begin\r
+        ShowMessage('The Current Document is not a Protel PCB Document.');\r
+        Exit;\r
+    End;\r
+    \r
+    // Setup Board iterator\r
+    Iterator        := Board.BoardIterator_Create; \r
+    Iterator.AddFilter_ObjectSet(MkSet(eComponentObject)); \r
+    Iterator.AddFilter_LayerSet(AllLayers); \r
+    Iterator.AddFilter_Method(eProcessAll);\r
+    \r
+    Comp := Iterator.FirstPCBObject;\r
+    While (Comp <> Nil) Do\r
+    Begin\r
+        // On ne modifie pas le numéro du PCB, qui est la référence du logo de compagnie\r
+        If CompareString(Comp.Pattern, 'LOGOCOMPANY', 7) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        If CompareString(UpperCase(Comp.Pattern), 'MIRE', 4) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        If CompareString(UpperCase(Comp.Pattern), 'CRACK', 5) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        // On ne modifie pas les fiducials\r
+        If CompareString(UpperCase(Comp.Pattern), 'FIDG', 4) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+\r
+        // On ne modifie pas la légende des couches\r
+        If CompareString(UpperCase(Comp.Pattern), 'LAYERS', 6) Then\r
+        Begin\r
+           Comp := Iterator.NextPCBObject;\r
+           Continue;\r
+        End;\r
+        \r
+        // Call resize function\r
+        ResizeRefDes(Comp);\r
+        \r
+        Comp := Iterator.NextPCBObject;\r
+    End;\r
+    \r
+    Board.BoardIterator_Destroy(Iterator);\r
+    \r
+    Pcbserver.PostProcess;\r
+    Client.SendMessage('PCB:Zoom', 'Action=Redraw', 255, Client.CurrentView);\r
+End;\r
diff --git a/scripts/altium/pcb-resize-refdes-selection.pas b/scripts/altium/pcb-resize-refdes-selection.pas
new file mode 100644 (file)
index 0000000..63c4f5c
--- /dev/null
@@ -0,0 +1,33 @@
+// Summary: Change reference designator text size of the selected component.\r
+\r
+Procedure PCB_ResizeRefDes_Selection;\r
+Var\r
+    Board     : IPCB_Board;\r
+    Comp      : IPCB_Component;\r
+    x,y,      : TCoord;\r
+    \r
+Begin\r
+    Pcbserver.PreProcess;\r
+\r
+    Try\r
+        Board := PCBServer.GetCurrentPCBBoard;\r
+        If Not Assigned(Board) Then\r
+        Begin\r
+            ShowMessage('The Current Document is not a Protel PCB Document.');\r
+            Exit;\r
+        End;\r
+    \r
+        Board.ChooseLocation(x,y, 'Choose Component');\r
+        Comp := Board.GetObjectAtXYAskUserIfAmbiguous(x,y,MkSet(eComponentObject),AllLayers, eEditAction_Select);\r
+        If Not Assigned(Comp) Then Exit;\r
+        \r
+        // Call resize function\r
+        ResizeRefDes(Comp);\r
+\r
+    Finally\r
+        Pcbserver.PostProcess;\r
+        Client.SendMessage('PCB:Zoom', 'Action=Redraw', 255, Client.CurrentView);\r
+    End;\r
+    \r
+   \r
+End;\r
diff --git a/scripts/altium/sch-align-refdes-all.pas b/scripts/altium/sch-align-refdes-all.pas
new file mode 100644 (file)
index 0000000..2e79442
--- /dev/null
@@ -0,0 +1,45 @@
+// Alignement des attributs de tous les composants dans un schéma\r
+  \r
+Procedure SCH_ResizeRefDes_All;\r
+Var\r
+    CurrentSheet : ISch_Document;\r
+    Comp :         ISch_Component;\r
+    Iterator :     ISch_Iterator;\r
+              \r
+Begin\r
+    // Check if schematic server exists or not.\r
+    If SchServer = Nil Then Exit;\r
+  \r
+    CurrentSheet := SchServer.GetCurrentSchDocument;\r
+    If CurrentSheet = Nil Then\r
+    Begin\r
+        ShowMessage('The current document is not a schematic document.');\r
+        Exit;\r
+    End;\r
+  \r
+    Try\r
+        SchServer.ProcessControl.PreProcess(CurrentSheet, '');\r
+            \r
+        // Set up iterator to look for Component objects only\r
+        Iterator := CurrentSheet.SchIterator_Create;\r
+        If Iterator = Nil Then Exit;\r
+  \r
+        Iterator.AddFilter_ObjectSet(MkSet(eSchComponent));\r
+        Try\r
+            Comp := Iterator.FirstSchObject;\r
+            While Comp <> Nil Do\r
+            Begin\r
+                SCH_AlignRefDes(Comp);\r
+                Comp := Iterator.NextSchObject;\r
+            End;\r
+  \r
+        Finally\r
+            Currentsheet.SchIterator_Destroy(iterator);\r
+        End;\r
+  \r
+      Finally\r
+        SchServer.ProcessControl.PostProcess(CurrentSheet, '');\r
+    End;\r
+\r
+    CurrentSheet.GraphicallyInvalidate;\r
+End;\r
diff --git a/scripts/altium/sch-align-refdes-selection.pas b/scripts/altium/sch-align-refdes-selection.pas
new file mode 100644 (file)
index 0000000..211e18b
--- /dev/null
@@ -0,0 +1,46 @@
+// Alignement des attributs du composant sélectionné dans un schéma\r
+  \r
+Procedure SCH_AlignRefDes_Selection;\r
+Var\r
+    CurrentSheet : ISch_Document;\r
+    Comp :         ISch_Component;\r
+    Iterator :     ISch_Iterator;\r
+              \r
+Begin\r
+    // Check if schematic server exists or not.\r
+    If SchServer = Nil Then Exit;\r
+  \r
+    CurrentSheet := SchServer.GetCurrentSchDocument;\r
+    If CurrentSheet = Nil Then\r
+    Begin\r
+        ShowMessage('The current document is not a schematic document.');\r
+        Exit;\r
+    End;\r
+  \r
+    Try\r
+        SchServer.ProcessControl.PreProcess(CurrentSheet, '');\r
+            \r
+        // Set up iterator to look for Component objects only\r
+        Iterator := CurrentSheet.SchIterator_Create;\r
+        If Iterator = Nil Then Exit;\r
+  \r
+        Iterator.AddFilter_ObjectSet(MkSet(eSchComponent));\r
+        Try\r
+            Comp := Iterator.FirstSchObject;\r
+            While Comp <> Nil Do\r
+            Begin\r
+                // Alignement seulement si le composant a été sélectionné.\r
+                If Comp.Selection Then SCH_AlignRefDes(Comp);\r
+                Comp := Iterator.NextSchObject;\r
+            End;\r
+  \r
+        Finally\r
+            Currentsheet.SchIterator_Destroy(iterator);\r
+        End;\r
+  \r
+      Finally\r
+        SchServer.ProcessControl.PostProcess(CurrentSheet, '');\r
+    End;\r
+\r
+    CurrentSheet.GraphicallyInvalidate;\r
+End;\r
diff --git a/scripts/altium/sch-align-refdes.pas b/scripts/altium/sch-align-refdes.pas
new file mode 100644 (file)
index 0000000..1575f11
--- /dev/null
@@ -0,0 +1,262 @@
+// Alignement des attributs des composants dans un schéma\r
+\r
+// TODO:\r
+//   -Mettre attribut "Mirrored" à FALSE pour les R, C et L\r
+\r
+Const\r
+   DEFAULT_FONT_NAME = 'Arial';\r
+   DEFAULT_FONT_SIZE = 8;\r
+   \r
+   R_SYMBOL_LENGTH_MILS     =  400; // Longueur du symbole\r
+   R_SYMBOL_HEIGHT_MILS     =  050; // Hauteur du symbole\r
+   \r
+   C_DISPLAY_VOLTAGE        = True; // Affichage de l'attribut voltage\r
+   C_SYMBOL_LENGTH_MILS     =  300; // Longueur du symbole\r
+   C_SYMBOL_HEIGHT_MILS     =  160; // Hauteur du symbole\r
+   \r
+   L_SYMBOL_LENGTH_MILS     =  500; // Longueur du symbole\r
+   L_SYMBOL_HEIGHT_MILS     =  090; // Hauteur du symbole (2 différentes hauteurs, 50 et 100mil...)\r
+   \r
+   D_SYMBOL_LENGTH_MILS     =  400; // Longueur du symbole\r
+   D_SYMBOL_HEIGHT_MILS     =  150; // Hauteur du symbole (2 différentes hauteurs, 50 et 100mil...)\r
+\r
+   PARAM_OFFSET_MILS        =  025; // Distance entre le graphique et le texte\r
+   PARAM_TEXT_HEIGHT_ADJUST =  015; // Pour compenser la hauteur du texte si alignement vertical au centre.\r
+   PARAMS_Y_SEP             =  080; // Distance verticale entre 2 paramètres\r
+      \r
+   // global variables\r
+Var\r
+   FontID      : TFontID;\r
+   VALUE_POS   : Integer;\r
+   VOLTAGE_POS : Integer;\r
+   POWER_POS   : Integer;\r
+   CURRENT_POS : Integer;\r
+   MPN_POS     : Integer;\r
+   SymbolLengthMils : Integer;\r
+   SymbolHeightMils : Integer;\r
+   \r
+Function SCH_AnalyseComponent(Comp : ISch_Component);\r
+Var\r
+   s : String;\r
+      \r
+Begin\r
+    SymbolLengthMils := 0;\r
+    SymbolHeightMils := 0;\r
+\r
+    s := Copy(UpperCase(Comp.Designator.Text), 1, 1);\r
+   \r
+   If s = 'R' Then Begin\r
+      SymbolLengthMils := R_SYMBOL_LENGTH_MILS;\r
+      SymbolHeightMils := R_SYMBOL_HEIGHT_MILS;\r
+      VALUE_POS   := 0;\r
+      POWER_POS   := 1;\r
+   End;\r
+   If s = 'L' Then Begin\r
+      SymbolLengthMils := L_SYMBOL_LENGTH_MILS;\r
+      SymbolHeightMils := L_SYMBOL_HEIGHT_MILS;\r
+      VALUE_POS   := 0;\r
+      CURRENT_POS := 1;\r
+   End;\r
+   If s = 'C' Then Begin\r
+      SymbolLengthMils := C_SYMBOL_LENGTH_MILS;\r
+      SymbolHeightMils := C_SYMBOL_HEIGHT_MILS;\r
+      VALUE_POS   := 0;\r
+      VOLTAGE_POS := 1;\r
+   End;\r
+   If s = 'D' Then Begin\r
+      SymbolLengthMils := D_SYMBOL_LENGTH_MILS;\r
+      SymbolHeightMils := D_SYMBOL_HEIGHT_MILS;\r
+      VALUE_POS   := 0; // For LEDs, VALUE = COLOR \r
+      VOLTAGE_POS := 0;\r
+      CURRENT_POS := 1;\r
+      POWER_POS   := 1;\r
+      MPN_POS     := 2;\r
+   End;\r
+   \r
+   // Pour avoir les ajustements à partir du milieu du composant\r
+   SymbolLengthMils := SymbolLengthMils / 2;\r
+   SymbolHeightMils := SymbolHeightMils / 2;\r
+End;\r
+\r
+\r
+Function SCH_ProcessRefDes(Comp : ISch_Component; Parameter : ISch_Parameter);\r
+Var\r
+   CompLoc        : TLocation; // Position du composant\r
+   ParamLoc       : TLocation;\r
+   DX, DY         : Integer;   // Position du paramètre (delta par rapport au composant)\r
+   ParamOffset    : Integer;\r
+   ParamJust      : TTextJustification;\r
+   s          : String;\r
+Begin\r
+   DX := 0;\r
+   DY := 0;\r
+   \r
+   s := Copy(UpperCase(Comp.Designator.Text), 1, 1);\r
+\r
+   // Trouve le X de départ, en Y le milieu du composant\r
+   Case Comp.Orientation of\r
+      eRotate0   :\r
+         Begin\r
+            DX := SymbolLengthMils;\r
+         End;\r
+      eRotate90  :\r
+         Begin\r
+            DX := SymbolHeightMils + PARAM_OFFSET_MILS;\r
+            DY := SymbolLengthMils;\r
+         End;\r
+      eRotate180 :\r
+         Begin\r
+            DX := - SymbolLengthMils;\r
+         End;\r
+      eRotate270 :\r
+         Begin\r
+            DX := SymbolHeightMils + PARAM_OFFSET_MILS;\r
+            DY := - SymbolLengthMils;\r
+         End;\r
+   End;\r
+   \r
+   Case Comp.Orientation of\r
+      eRotate0,  eRotate180 :\r
+         Begin\r
+            ParamJust := eJustify_Center;\r
+            If Parameter = Nil Then\r
+               DY := SymbolHeightMils + PARAM_OFFSET_MILS + PARAM_TEXT_HEIGHT_ADJUST; // Designator\r
+         end;\r
+      eRotate90, eRotate270 :\r
+         Begin\r
+            ParamJust := eJustify_CenterLeft;\r
+            If Parameter = Nil Then // Designator\r
+               DY := DY + PARAMS_Y_SEP; // Devrait changer selon le nombre de paramètres à afficher\r
+         End;\r
+   End;\r
+   \r
+   If Parameter <> Nil Then\r
+   Begin\r
+       ParamOffset := -1;\r
+   \r
+       // Process Parameter, not designator\r
+       If CompareString(UpperCase(Parameter.Name), 'VALUE', 5) Then\r
+       Begin\r
+           ParamOffset := VALUE_POS;\r
+       End;\r
+\r
+       If CompareString(UpperCase(Parameter.Name), 'VOLTAGE', 7) Then\r
+       Begin\r
+           If s = 'C' Then Parameter.IsHidden := False; // force display of voltage parameter\r
+           ParamOffset := VOLTAGE_POS;\r
+       End;\r
+      \r
+       If CompareString(UpperCase(Parameter.Name), 'POWER', 5) Then\r
+       Begin\r
+           ParamOffset := POWER_POS;\r
+       End;\r
+      \r
+       If CompareString(UpperCase(Parameter.Name), 'CURRENT', 7) Then\r
+       Begin\r
+           ParamOffset := CURRENT_POS;\r
+       End;\r
+\r
+       If CompareString(UpperCase(Parameter.Name), 'MPN', 3) Then\r
+       Begin\r
+           ParamOffset := MPN_POS;\r
+       End;\r
+\r
+       If ParamOffset < 0 Then\r
+       Begin\r
+           ParamOffset := 2; // TEMP!!!!!!!\r
+       End;\r
+\r
+       Case Comp.Orientation of\r
+          eRotate0,  eRotate180 :\r
+          Begin\r
+              DY := - (SymbolHeightMils + PARAM_OFFSET_MILS + PARAM_TEXT_HEIGHT_ADJUST + (PARAMS_Y_SEP * ParamOffset));\r
+          end;\r
+            eRotate90, eRotate270 :\r
+            Begin\r
+                DY := DY - (PARAMS_Y_SEP * ParamOffset);\r
+            End;\r
+        End;\r
+\r
+   End;\r
+   \r
+   // Debug\r
+   If s = 'X' Then\r
+   Begin\r
+      If Parameter = Nil Then\r
+         ShowMessage('LOC = ' + IntToStr(DX) + ',' + IntToStr(DY));\r
+   End;\r
+   \r
+   CompLoc := Comp.GetState_Location;\r
+   ParamLoc := CompLoc;\r
+   ParamLoc.X := ParamLoc.X + MilsToCoord(DX);\r
+   ParamLoc.Y := ParamLoc.Y + MilsToCoord(DY);\r
+   \r
+   If Parameter = Nil Then\r
+   Begin\r
+      // Designator\r
+      Comp.Designator.Justification := ParamJust;\r
+      Comp.Designator.SetState_Location(ParamLoc);\r
+      Comp.Designator.Orientation := eRotate0;\r
+   End\r
+   Else\r
+   Begin\r
+      Parameter.Justification := ParamJust;\r
+      Parameter.SetState_Location(ParamLoc);\r
+      Parameter.SetState_Orientation(eRotate0);\r
+   End;\r
+   \r
+End;\r
+\r
+// Standardisation de la police de caractère     \r
+Function SCH_SetFont(Comp : ISch_Component; Parameter : ISch_Parameter);\r
+Var\r
+   s                : String;\r
+Begin\r
+   If Parameter = Nil Then\r
+      Comp.Designator.FontId := FontID // Designator\r
+   Else\r
+      Parameter.FontId := FontID;\r
+End;\r
+\r
+Function SCH_AlignRefDes(Comp : ISch_Component);\r
+Var\r
+   PIterator  : ISch_Iterator;\r
+   Parameter  : ISch_Parameter;\r
+Begin\r
+    FontID := SchServer.FontManager.GetFontID(DEFAULT_FONT_SIZE,0,False,False,False,False, DEFAULT_FONT_NAME);\r
+\r
+    Try\r
+        VALUE_POS   := -1;\r
+        VOLTAGE_POS := -1;\r
+        POWER_POS   := -1;\r
+        CURRENT_POS := -1;\r
+        MPN_POS     := -1;\r
+\r
+        SCH_SetFont(Comp, Nil);\r
+        SCH_AnalyseComponent(Comp);\r
+\r
+        If SymbolLengthMils <> 0 Then\r
+            SCH_ProcessRefDes(Comp, Nil);\r
+                          \r
+        PIterator := Comp.SchIterator_Create;\r
+        PIterator.AddFilter_ObjectSet(MkSet(eParameter));\r
+            \r
+        Parameter := PIterator.FirstSchObject;\r
+        While Parameter <> Nil Do\r
+        Begin\r
+           If CompareString(UpperCase(Parameter.Name), 'COMMENT', 7) Then\r
+           Begin\r
+              // Pour ne pas afficher le commentaire (#compagnie)\r
+              Parameter.IsHidden := True;\r
+           End\r
+           Else\r
+              If SymbolLengthMils <> 0 Then\r
+                  SCH_ProcessRefDes(Comp, Parameter);\r
+                  \r
+              SCH_SetFont(Comp, Parameter);\r
+              Parameter := PIterator.NextSchObject;\r
+           End;\r
+    Finally\r
+        Comp.SchIterator_Destroy(PIterator);\r
+    End;\r
+End;\r
diff --git a/scripts/altium/scripts.PrjScr b/scripts/altium/scripts.PrjScr
new file mode 100644 (file)
index 0000000..efecd15
--- /dev/null
@@ -0,0 +1,1066 @@
+[Design]\r
+Version=1.0\r
+HierarchyMode=0\r
+ChannelRoomNamingStyle=0\r
+OutputPath=\r
+LogFolderPath=\r
+ReleasesFolder=\r
+ReleaseVaultGUID=\r
+ReleaseVaultName=\r
+ChannelDesignatorFormatString=$Component_$RoomName\r
+ChannelRoomLevelSeperator=_\r
+OpenOutputs=1\r
+ArchiveProject=0\r
+TimestampOutput=0\r
+SeparateFolders=0\r
+TemplateLocationPath=\r
+PinSwapBy_Netlabel=1\r
+PinSwapBy_Pin=1\r
+AllowPortNetNames=0\r
+AllowSheetEntryNetNames=1\r
+AppendSheetNumberToLocalNets=0\r
+NetlistSinglePinNets=0\r
+DefaultConfiguration=\r
+UserID=0xFFFFFFFF\r
+DefaultPcbProtel=1\r
+DefaultPcbPcad=0\r
+ReorderDocumentsOnCompile=1\r
+NameNetsHierarchically=0\r
+PowerPortNamesTakePriority=0\r
+PushECOToAnnotationFile=1\r
+DItemRevisionGUID=\r
+ReportSuppressedErrorsInMessages=0\r
+\r
+[Document1]\r
+DocumentPath=functions.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document2]\r
+DocumentPath=cleanlib.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document3]\r
+DocumentPath=pcb-resize-refdes-all.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document4]\r
+DocumentPath=pcb-assembly-drawings.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document5]\r
+DocumentPath=pcb-lit-de-clou.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document6]\r
+DocumentPath=sch-align-refdes.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document7]\r
+DocumentPath=sch-align-refdes-all.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document8]\r
+DocumentPath=pcb-resize-refdes-selection.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[Document9]\r
+DocumentPath=sch-align-refdes-selection.pas\r
+AnnotationEnabled=1\r
+AnnotateStartValue=1\r
+AnnotationIndexControlEnabled=0\r
+AnnotateSuffix=\r
+AnnotateScope=All\r
+AnnotateOrder=-1\r
+DoLibraryUpdate=1\r
+DoDatabaseUpdate=1\r
+ClassGenCCAutoEnabled=1\r
+ClassGenCCAutoRoomEnabled=1\r
+ClassGenNCAutoScope=None\r
+DItemRevisionGUID=\r
+GenerateClassCluster=0\r
+\r
+[PCBConfiguration1]\r
+ReleaseItemId=\r
+CurrentRevision=\r
+Name=Default Configuration\r
+Variant=[No Variations]\r
+GenerateBOM=0\r
+\r
+[OutputGroup1]\r
+Name=Netlist Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=EDIF\r
+OutputName1=EDIF for PCB\r
+OutputDocumentPath1=\r
+OutputVariantName1=\r
+OutputDefault1=0\r
+OutputType2=MultiWire\r
+OutputName2=MultiWire\r
+OutputDocumentPath2=\r
+OutputVariantName2=\r
+OutputDefault2=0\r
+OutputType3=Pcad\r
+OutputName3=Pcad for PCB\r
+OutputDocumentPath3=\r
+OutputVariantName3=\r
+OutputDefault3=0\r
+OutputType4=ProtelNetlist\r
+OutputName4=Protel\r
+OutputDocumentPath4=\r
+OutputVariantName4=\r
+OutputDefault4=0\r
+OutputType5=SIMetrixNetlist\r
+OutputName5=SIMetrix\r
+OutputDocumentPath5=\r
+OutputVariantName5=\r
+OutputDefault5=0\r
+OutputType6=SIMPLISNetlist\r
+OutputName6=SIMPLIS\r
+OutputDocumentPath6=\r
+OutputVariantName6=\r
+OutputDefault6=0\r
+OutputType7=Verilog\r
+OutputName7=Verilog File\r
+OutputDocumentPath7=\r
+OutputVariantName7=\r
+OutputDefault7=0\r
+OutputType8=VHDL\r
+OutputName8=VHDL File\r
+OutputDocumentPath8=\r
+OutputVariantName8=\r
+OutputDefault8=0\r
+OutputType9=XSpiceNetlist\r
+OutputName9=XSpice Netlist\r
+OutputDocumentPath9=\r
+OutputVariantName9=\r
+OutputDefault9=0\r
+OutputType10=CadnetixNetlist\r
+OutputName10=Cadnetix Netlist\r
+OutputDocumentPath10=\r
+OutputVariantName10=\r
+OutputDefault10=0\r
+OutputType11=CalayNetlist\r
+OutputName11=Calay Netlist\r
+OutputDocumentPath11=\r
+OutputVariantName11=\r
+OutputDefault11=0\r
+OutputType12=EESofNetlist\r
+OutputName12=EESof Netlist\r
+OutputDocumentPath12=\r
+OutputVariantName12=\r
+OutputDefault12=0\r
+OutputType13=IntergraphNetlist\r
+OutputName13=Intergraph Netlist\r
+OutputDocumentPath13=\r
+OutputVariantName13=\r
+OutputDefault13=0\r
+OutputType14=MentorBoardStationNetlist\r
+OutputName14=Mentor BoardStation Netlist\r
+OutputDocumentPath14=\r
+OutputVariantName14=\r
+OutputDefault14=0\r
+OutputType15=OrCadPCB2Netlist\r
+OutputName15=Orcad/PCB2 Netlist\r
+OutputDocumentPath15=\r
+OutputVariantName15=\r
+OutputDefault15=0\r
+OutputType16=PADSNetlist\r
+OutputName16=PADS ASCII Netlist\r
+OutputDocumentPath16=\r
+OutputVariantName16=\r
+OutputDefault16=0\r
+OutputType17=PCADNetlist\r
+OutputName17=PCAD Netlist\r
+OutputDocumentPath17=\r
+OutputVariantName17=\r
+OutputDefault17=0\r
+OutputType18=PCADnltNetlist\r
+OutputName18=PCADnlt Netlist\r
+OutputDocumentPath18=\r
+OutputVariantName18=\r
+OutputDefault18=0\r
+OutputType19=Protel2Netlist\r
+OutputName19=Protel2 Netlist\r
+OutputDocumentPath19=\r
+OutputVariantName19=\r
+OutputDefault19=0\r
+OutputType20=RacalNetlist\r
+OutputName20=Racal Netlist\r
+OutputDocumentPath20=\r
+OutputVariantName20=\r
+OutputDefault20=0\r
+OutputType21=RINFNetlist\r
+OutputName21=RINF Netlist\r
+OutputDocumentPath21=\r
+OutputVariantName21=\r
+OutputDefault21=0\r
+OutputType22=SciCardsNetlist\r
+OutputName22=SciCards Netlist\r
+OutputDocumentPath22=\r
+OutputVariantName22=\r
+OutputDefault22=0\r
+OutputType23=TangoNetlist\r
+OutputName23=Tango Netlist\r
+OutputDocumentPath23=\r
+OutputVariantName23=\r
+OutputDefault23=0\r
+OutputType24=TelesisNetlist\r
+OutputName24=Telesis Netlist\r
+OutputDocumentPath24=\r
+OutputVariantName24=\r
+OutputDefault24=0\r
+OutputType25=WireListNetlist\r
+OutputName25=WireList Netlist\r
+OutputDocumentPath25=\r
+OutputVariantName25=\r
+OutputDefault25=0\r
+\r
+[OutputGroup2]\r
+Name=Simulator Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=AdvSimNetlist\r
+OutputName1=Mixed Sim\r
+OutputDocumentPath1=\r
+OutputVariantName1=\r
+OutputDefault1=0\r
+OutputType2=SIMetrix_Sim\r
+OutputName2=SIMetrix\r
+OutputDocumentPath2=\r
+OutputVariantName2=\r
+OutputDefault2=0\r
+OutputType3=SIMPLIS_Sim\r
+OutputName3=SIMPLIS\r
+OutputDocumentPath3=\r
+OutputVariantName3=\r
+OutputDefault3=0\r
+\r
+[OutputGroup3]\r
+Name=Documentation Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=Composite\r
+OutputName1=Composite Drawing\r
+OutputDocumentPath1=\r
+OutputVariantName1=\r
+OutputDefault1=0\r
+PageOptions1=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType2=Logic Analyser Print\r
+OutputName2=Logic Analyser Prints\r
+OutputDocumentPath2=\r
+OutputVariantName2=\r
+OutputDefault2=0\r
+PageOptions2=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType3=OpenBus Print\r
+OutputName3=OpenBus Prints\r
+OutputDocumentPath3=\r
+OutputVariantName3=\r
+OutputDefault3=0\r
+PageOptions3=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType4=PCB 3D Print\r
+OutputName4=PCB 3D Prints\r
+OutputDocumentPath4=\r
+OutputVariantName4=[No Variations]\r
+OutputDefault4=0\r
+PageOptions4=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType5=PCB Print\r
+OutputName5=PCB Prints\r
+OutputDocumentPath5=\r
+OutputVariantName5=\r
+OutputDefault5=0\r
+PageOptions5=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType6=Schematic Print\r
+OutputName6=Schematic Prints\r
+OutputDocumentPath6=\r
+OutputVariantName6=\r
+OutputDefault6=0\r
+PageOptions6=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType7=SimView Print\r
+OutputName7=SimView Prints\r
+OutputDocumentPath7=\r
+OutputVariantName7=\r
+OutputDefault7=0\r
+PageOptions7=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType8=Wave Print\r
+OutputName8=Wave Prints\r
+OutputDocumentPath8=\r
+OutputVariantName8=\r
+OutputDefault8=0\r
+PageOptions8=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType9=Assembler Source Print\r
+OutputName9=Assembler Source Prints\r
+OutputDocumentPath9=\r
+OutputVariantName9=\r
+OutputDefault9=0\r
+PageOptions9=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType10=C Source Print\r
+OutputName10=C Source Prints\r
+OutputDocumentPath10=\r
+OutputVariantName10=\r
+OutputDefault10=0\r
+PageOptions10=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType11=C/C++ Header Print\r
+OutputName11=C/C++ Header Prints\r
+OutputDocumentPath11=\r
+OutputVariantName11=\r
+OutputDefault11=0\r
+PageOptions11=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType12=C++ Source Print\r
+OutputName12=C++ Source Prints\r
+OutputDocumentPath12=\r
+OutputVariantName12=\r
+OutputDefault12=0\r
+PageOptions12=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType13=PCB 3D Video\r
+OutputName13=PCB 3D Video\r
+OutputDocumentPath13=\r
+OutputVariantName13=[No Variations]\r
+OutputDefault13=0\r
+PageOptions13=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType14=Report Print\r
+OutputName14=Report Prints\r
+OutputDocumentPath14=\r
+OutputVariantName14=\r
+OutputDefault14=0\r
+PageOptions14=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType15=Software Platform Print\r
+OutputName15=Software Platform Prints\r
+OutputDocumentPath15=\r
+OutputVariantName15=\r
+OutputDefault15=0\r
+PageOptions15=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType16=VHDL Print\r
+OutputName16=VHDL Prints\r
+OutputDocumentPath16=\r
+OutputVariantName16=\r
+OutputDefault16=0\r
+PageOptions16=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType17=WaveSim Print\r
+OutputName17=WaveSim Prints\r
+OutputDocumentPath17=\r
+OutputVariantName17=\r
+OutputDefault17=0\r
+PageOptions17=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+\r
+[OutputGroup4]\r
+Name=Assembly Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=Assembly\r
+OutputName1=Assembly Drawings\r
+OutputDocumentPath1=\r
+OutputVariantName1=[No Variations]\r
+OutputDefault1=0\r
+PageOptions1=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType2=Pick Place\r
+OutputName2=Generates pick and place files\r
+OutputDocumentPath2=\r
+OutputVariantName2=[No Variations]\r
+OutputDefault2=0\r
+OutputType3=Test Points For Assembly\r
+OutputName3=Test Point Report\r
+OutputDocumentPath3=\r
+OutputVariantName3=[No Variations]\r
+OutputDefault3=0\r
+\r
+[OutputGroup5]\r
+Name=Fabrication Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=CompositeDrill\r
+OutputName1=Composite Drill Drawing\r
+OutputDocumentPath1=\r
+OutputVariantName1=[No Variations]\r
+OutputDefault1=0\r
+PageOptions1=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType2=Drill\r
+OutputName2=Drill Drawing/Guides\r
+OutputDocumentPath2=\r
+OutputVariantName2=[No Variations]\r
+OutputDefault2=0\r
+PageOptions2=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType3=Final\r
+OutputName3=Final Artwork Prints\r
+OutputDocumentPath3=\r
+OutputVariantName3=[No Variations]\r
+OutputDefault3=0\r
+PageOptions3=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType4=Gerber\r
+OutputName4=Gerber Files\r
+OutputDocumentPath4=\r
+OutputVariantName4=[No Variations]\r
+OutputDefault4=0\r
+OutputType5=Mask\r
+OutputName5=Solder/Paste Mask Prints\r
+OutputDocumentPath5=\r
+OutputVariantName5=\r
+OutputDefault5=0\r
+PageOptions5=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType6=NC Drill\r
+OutputName6=NC Drill Files\r
+OutputDocumentPath6=\r
+OutputVariantName6=\r
+OutputDefault6=0\r
+OutputType7=ODB\r
+OutputName7=ODB++ Files\r
+OutputDocumentPath7=\r
+OutputVariantName7=[No Variations]\r
+OutputDefault7=0\r
+OutputType8=Plane\r
+OutputName8=Power-Plane Prints\r
+OutputDocumentPath8=\r
+OutputVariantName8=\r
+OutputDefault8=0\r
+PageOptions8=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType9=Test Points\r
+OutputName9=Test Point Report\r
+OutputDocumentPath9=\r
+OutputVariantName9=\r
+OutputDefault9=0\r
+\r
+[OutputGroup6]\r
+Name=Report Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=BOM_PartType\r
+OutputName1=Bill of Materials\r
+OutputDocumentPath1=\r
+OutputVariantName1=[No Variations]\r
+OutputDefault1=0\r
+PageOptions1=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType2=ComponentCrossReference\r
+OutputName2=Component Cross Reference Report\r
+OutputDocumentPath2=\r
+OutputVariantName2=[No Variations]\r
+OutputDefault2=0\r
+OutputType3=ReportHierarchy\r
+OutputName3=Report Project Hierarchy\r
+OutputDocumentPath3=\r
+OutputVariantName3=[No Variations]\r
+OutputDefault3=0\r
+OutputType4=SimpleBOM\r
+OutputName4=Simple BOM\r
+OutputDocumentPath4=\r
+OutputVariantName4=[No Variations]\r
+OutputDefault4=0\r
+OutputType5=SinglePinNetReporter\r
+OutputName5=Report Single Pin Nets\r
+OutputDocumentPath5=\r
+OutputVariantName5=[No Variations]\r
+OutputDefault5=0\r
+OutputType6=Script\r
+OutputName6=Script Output\r
+OutputDocumentPath6=\r
+OutputVariantName6=[No Variations]\r
+OutputDefault6=0\r
+\r
+[OutputGroup7]\r
+Name=Other Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=Text Print\r
+OutputName1=Text Print\r
+OutputDocumentPath1=\r
+OutputVariantName1=\r
+OutputDefault1=0\r
+PageOptions1=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType2=Text Print\r
+OutputName2=Text Print\r
+OutputDocumentPath2=\r
+OutputVariantName2=\r
+OutputDefault2=0\r
+PageOptions2=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType3=Text Print\r
+OutputName3=Text Print\r
+OutputDocumentPath3=\r
+OutputVariantName3=\r
+OutputDefault3=0\r
+PageOptions3=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType4=Text Print\r
+OutputName4=Text Print\r
+OutputDocumentPath4=\r
+OutputVariantName4=\r
+OutputDefault4=0\r
+PageOptions4=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType5=Text Print\r
+OutputName5=Text Print\r
+OutputDocumentPath5=\r
+OutputVariantName5=\r
+OutputDefault5=0\r
+PageOptions5=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType6=Text Print\r
+OutputName6=Text Print\r
+OutputDocumentPath6=\r
+OutputVariantName6=\r
+OutputDefault6=0\r
+PageOptions6=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType7=Text Print\r
+OutputName7=Text Print\r
+OutputDocumentPath7=\r
+OutputVariantName7=\r
+OutputDefault7=0\r
+PageOptions7=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType8=Text Print\r
+OutputName8=Text Print\r
+OutputDocumentPath8=\r
+OutputVariantName8=\r
+OutputDefault8=0\r
+PageOptions8=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType9=Text Print\r
+OutputName9=Text Print\r
+OutputDocumentPath9=\r
+OutputVariantName9=\r
+OutputDefault9=0\r
+PageOptions9=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType10=Text Print\r
+OutputName10=Text Print\r
+OutputDocumentPath10=\r
+OutputVariantName10=\r
+OutputDefault10=0\r
+PageOptions10=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType11=Text Print\r
+OutputName11=Text Print\r
+OutputDocumentPath11=\r
+OutputVariantName11=\r
+OutputDefault11=0\r
+PageOptions11=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType12=Text Print\r
+OutputName12=Text Print\r
+OutputDocumentPath12=\r
+OutputVariantName12=\r
+OutputDefault12=0\r
+PageOptions12=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType13=Text Print\r
+OutputName13=Text Print\r
+OutputDocumentPath13=\r
+OutputVariantName13=\r
+OutputDefault13=0\r
+PageOptions13=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType14=Text Print\r
+OutputName14=Text Print\r
+OutputDocumentPath14=\r
+OutputVariantName14=\r
+OutputDefault14=0\r
+PageOptions14=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType15=Text Print\r
+OutputName15=Text Print\r
+OutputDocumentPath15=\r
+OutputVariantName15=\r
+OutputDefault15=0\r
+PageOptions15=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType16=Text Print\r
+OutputName16=Text Print\r
+OutputDocumentPath16=\r
+OutputVariantName16=\r
+OutputDefault16=0\r
+PageOptions16=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType17=Text Print\r
+OutputName17=Text Print\r
+OutputDocumentPath17=\r
+OutputVariantName17=\r
+OutputDefault17=0\r
+PageOptions17=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType18=Text Print\r
+OutputName18=Text Print\r
+OutputDocumentPath18=\r
+OutputVariantName18=\r
+OutputDefault18=0\r
+PageOptions18=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType19=Text Print\r
+OutputName19=Text Print\r
+OutputDocumentPath19=\r
+OutputVariantName19=\r
+OutputDefault19=0\r
+PageOptions19=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType20=Text Print\r
+OutputName20=Text Print\r
+OutputDocumentPath20=\r
+OutputVariantName20=\r
+OutputDefault20=0\r
+PageOptions20=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType21=Text Print\r
+OutputName21=Text Print\r
+OutputDocumentPath21=\r
+OutputVariantName21=\r
+OutputDefault21=0\r
+PageOptions21=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType22=Text Print\r
+OutputName22=Text Print\r
+OutputDocumentPath22=\r
+OutputVariantName22=\r
+OutputDefault22=0\r
+PageOptions22=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType23=Text Print\r
+OutputName23=Text Print\r
+OutputDocumentPath23=\r
+OutputVariantName23=\r
+OutputDefault23=0\r
+PageOptions23=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType24=Text Print\r
+OutputName24=Text Print\r
+OutputDocumentPath24=\r
+OutputVariantName24=\r
+OutputDefault24=0\r
+PageOptions24=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType25=Text Print\r
+OutputName25=Text Print\r
+OutputDocumentPath25=\r
+OutputVariantName25=\r
+OutputDefault25=0\r
+PageOptions25=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType26=Text Print\r
+OutputName26=Text Print\r
+OutputDocumentPath26=\r
+OutputVariantName26=\r
+OutputDefault26=0\r
+PageOptions26=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType27=Text Print\r
+OutputName27=Text Print\r
+OutputDocumentPath27=\r
+OutputVariantName27=\r
+OutputDefault27=0\r
+PageOptions27=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType28=Text Print\r
+OutputName28=Text Print\r
+OutputDocumentPath28=\r
+OutputVariantName28=\r
+OutputDefault28=0\r
+PageOptions28=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType29=Text Print\r
+OutputName29=Text Print\r
+OutputDocumentPath29=\r
+OutputVariantName29=\r
+OutputDefault29=0\r
+PageOptions29=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+\r
+[OutputGroup8]\r
+Name=Validation Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=Design Rules Check\r
+OutputName1=Design Rules Check\r
+OutputDocumentPath1=\r
+OutputVariantName1=\r
+OutputDefault1=0\r
+PageOptions1=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType2=Differences Report\r
+OutputName2=Differences Report\r
+OutputDocumentPath2=\r
+OutputVariantName2=\r
+OutputDefault2=0\r
+PageOptions2=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType3=Electrical Rules Check\r
+OutputName3=Electrical Rules Check\r
+OutputDocumentPath3=\r
+OutputVariantName3=\r
+OutputDefault3=0\r
+PageOptions3=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+OutputType4=Footprint Comparison Report\r
+OutputName4=Footprint Comparison Report\r
+OutputDocumentPath4=\r
+OutputVariantName4=\r
+OutputDefault4=0\r
+\r
+[OutputGroup9]\r
+Name=Export Outputs\r
+Description=\r
+TargetPrinter=HP LaserJet 1020\r
+PrinterOptions=Record=PrinterOptions|Copies=1|Duplex=1|TrueTypeOptions=3|Collate=1|PrintWhat=1\r
+OutputType1=ExportSTEP\r
+OutputName1=Export STEP\r
+OutputDocumentPath1=\r
+OutputVariantName1=\r
+OutputDefault1=0\r
+\r
+[Modification Levels]\r
+Type1=1\r
+Type2=1\r
+Type3=1\r
+Type4=1\r
+Type5=1\r
+Type6=1\r
+Type7=1\r
+Type8=1\r
+Type9=1\r
+Type10=1\r
+Type11=1\r
+Type12=1\r
+Type13=1\r
+Type14=1\r
+Type15=1\r
+Type16=1\r
+Type17=1\r
+Type18=1\r
+Type19=1\r
+Type20=1\r
+Type21=1\r
+Type22=1\r
+Type23=1\r
+Type24=1\r
+Type25=1\r
+Type26=1\r
+Type27=1\r
+Type28=1\r
+Type29=1\r
+Type30=1\r
+Type31=1\r
+Type32=1\r
+Type33=1\r
+Type34=1\r
+Type35=1\r
+Type36=1\r
+Type37=1\r
+Type38=1\r
+Type39=1\r
+Type40=1\r
+Type41=1\r
+Type42=1\r
+Type43=1\r
+Type44=1\r
+Type45=1\r
+Type46=1\r
+Type47=1\r
+Type48=1\r
+Type49=1\r
+Type50=1\r
+Type51=1\r
+Type52=1\r
+Type53=1\r
+Type54=1\r
+Type55=1\r
+Type56=1\r
+Type57=1\r
+Type58=1\r
+Type59=1\r
+Type60=1\r
+Type61=1\r
+Type62=1\r
+Type63=1\r
+Type64=1\r
+Type65=1\r
+Type66=1\r
+Type67=1\r
+Type68=1\r
+Type69=1\r
+Type70=1\r
+Type71=1\r
+Type72=1\r
+Type73=1\r
+Type74=1\r
+\r
+[Difference Levels]\r
+Type1=1\r
+Type2=1\r
+Type3=1\r
+Type4=1\r
+Type5=1\r
+Type6=1\r
+Type7=1\r
+Type8=1\r
+Type9=1\r
+Type10=1\r
+Type11=1\r
+Type12=1\r
+Type13=1\r
+Type14=1\r
+Type15=1\r
+Type16=1\r
+Type17=1\r
+Type18=1\r
+Type19=1\r
+Type20=1\r
+Type21=1\r
+Type22=1\r
+Type23=1\r
+Type24=1\r
+Type25=1\r
+Type26=1\r
+Type27=1\r
+Type28=1\r
+Type29=1\r
+Type30=1\r
+Type31=1\r
+Type32=1\r
+Type33=1\r
+Type34=1\r
+Type35=1\r
+Type36=1\r
+Type37=1\r
+Type38=1\r
+Type39=1\r
+Type40=1\r
+\r
+[Electrical Rules Check]\r
+Type1=1\r
+Type2=1\r
+Type3=2\r
+Type4=1\r
+Type5=2\r
+Type6=2\r
+Type7=1\r
+Type8=1\r
+Type9=1\r
+Type10=1\r
+Type11=2\r
+Type12=2\r
+Type13=2\r
+Type14=1\r
+Type15=1\r
+Type16=1\r
+Type17=1\r
+Type18=1\r
+Type19=1\r
+Type20=1\r
+Type21=1\r
+Type22=1\r
+Type23=1\r
+Type24=1\r
+Type25=2\r
+Type26=2\r
+Type27=2\r
+Type28=1\r
+Type29=1\r
+Type30=1\r
+Type31=1\r
+Type32=2\r
+Type33=2\r
+Type34=2\r
+Type35=1\r
+Type36=2\r
+Type37=1\r
+Type38=2\r
+Type39=2\r
+Type40=2\r
+Type41=0\r
+Type42=2\r
+Type43=1\r
+Type44=1\r
+Type45=2\r
+Type46=1\r
+Type47=2\r
+Type48=2\r
+Type49=1\r
+Type50=2\r
+Type51=1\r
+Type52=1\r
+Type53=1\r
+Type54=1\r
+Type55=1\r
+Type56=2\r
+Type57=1\r
+Type58=1\r
+Type59=0\r
+Type60=1\r
+Type61=2\r
+Type62=2\r
+Type63=1\r
+Type64=0\r
+Type65=2\r
+Type66=3\r
+Type67=2\r
+Type68=2\r
+Type69=1\r
+Type70=2\r
+Type71=2\r
+Type72=2\r
+Type73=2\r
+Type74=1\r
+Type75=2\r
+Type76=1\r
+Type77=1\r
+Type78=1\r
+Type79=1\r
+Type80=2\r
+Type81=3\r
+Type82=3\r
+Type83=3\r
+Type84=3\r
+Type85=3\r
+Type86=2\r
+Type87=2\r
+Type88=2\r
+Type89=1\r
+Type90=1\r
+Type91=3\r
+Type92=3\r
+Type93=2\r
+Type94=2\r
+Type95=2\r
+Type96=2\r
+Type97=2\r
+Type98=0\r
+Type99=1\r
+Type100=2\r
+\r
+[ERC Connection Matrix]\r
+L1=NNNNNNNNNNNWNNNWW\r
+L2=NNWNNNNWWWNWNWNWN\r
+L3=NWEENEEEENEWNEEWN\r
+L4=NNENNNWEENNWNENWN\r
+L5=NNNNNNNNNNNNNNNNN\r
+L6=NNENNNNEENNWNENWN\r
+L7=NNEWNNWEENNWNENWN\r
+L8=NWEENEENEEENNEENN\r
+L9=NWEENEEEENEWNEEWW\r
+L10=NWNNNNNENNEWNNEWN\r
+L11=NNENNNNEEENWNENWN\r
+L12=WWWWNWWNWWWNWWWNN\r
+L13=NNNNNNNNNNNWNNNWW\r
+L14=NWEENEEEENEWNEEWW\r
+L15=NNENNNNEEENWNENWW\r
+L16=WWWWNWWNWWWNWWWNW\r
+L17=WNNNNNNNWNNNWWWWN\r
+\r
+[Annotate]\r
+SortOrder=3\r
+MatchParameter1=Comment\r
+MatchStrictly1=1\r
+MatchParameter2=Library Reference\r
+MatchStrictly2=1\r
+PhysicalNamingFormat=$Component_$RoomName\r
+GlobalIndexSortOrder=3\r
+\r
+[PrjClassGen]\r
+CompClassManualEnabled=0\r
+CompClassManualRoomEnabled=0\r
+NetClassAutoBusEnabled=1\r
+NetClassAutoCompEnabled=0\r
+NetClassAutoNamedHarnessEnabled=0\r
+NetClassManualEnabled=0\r
+\r
+[LibraryUpdateOptions]\r
+SelectedOnly=0\r
+PartTypes=0\r
+FullReplace=1\r
+UpdateDesignatorLock=1\r
+UpdatePartIDLock=1\r
+PreserveParameterLocations=1\r
+DoGraphics=1\r
+DoParameters=1\r
+DoModels=1\r
+AddParameters=0\r
+RemoveParameters=0\r
+AddModels=1\r
+RemoveModels=1\r
+UpdateCurrentModels=1\r
+\r
+[DatabaseUpdateOptions]\r
+SelectedOnly=0\r
+PartTypes=0\r
+\r
+[Comparison Options]\r
+ComparisonOptions0=Kind=Net|MinPercent=75|MinMatch=3|ShowMatch=-1|Confirm=-1|UseName=-1|InclAllRules=0\r
+ComparisonOptions1=Kind=Net Class|MinPercent=75|MinMatch=3|ShowMatch=-1|Confirm=-1|UseName=-1|InclAllRules=0\r
+ComparisonOptions2=Kind=Component Class|MinPercent=75|MinMatch=3|ShowMatch=-1|Confirm=-1|UseName=-1|InclAllRules=0\r
+ComparisonOptions3=Kind=Rule|MinPercent=75|MinMatch=3|ShowMatch=-1|Confirm=-1|UseName=-1|InclAllRules=0\r
+ComparisonOptions4=Kind=Differential Pair|MinPercent=50|MinMatch=1|ShowMatch=0|Confirm=0|UseName=0|InclAllRules=0\r
+ComparisonOptions5=Kind=Structure Class|MinPercent=75|MinMatch=3|ShowMatch=-1|Confirm=-1|UseName=-1|InclAllRules=0\r
+\r
+[SmartPDF]\r
+PageOptions=Record=PageOptions|CenterHorizontal=True|CenterVertical=True|PrintScale=1.00|XCorrection=1.00|YCorrection=1.00|PrintKind=1|BorderSize=5000000|LeftOffset=0|BottomOffset=0|Orientation=2|PaperLength=1000|PaperWidth=1000|Scale=100|PaperSource=7|PrintQuality=-4|MediaType=1|DitherType=10|PaperKind=A4|PrintScaleMode=1\r
+\r