Пример #1
0
        private bool InternAddAcadObjectBlockEnd(ref AcadBlock robjAcadBlock, double vdblObjectID, double vdblOwnerID, int vlngPaperSpace, string vstrLayer, string vstrLinetype, int vlngColor, object vvarLinetypeScale, int vlngVisible, int vlngRGB, Enums.AcLineWeight vnumLineweight, string vstrPlotStyleNameReference, Dictionary <object, object> vobjDictReactors, ref string nrstrErrMsg)
        {
            AcadBlockEnd dobjAcadBlockEnd2           = robjAcadBlock.FriendAddAcadObjectBlockEnd(ref nrstrErrMsg, vdblObjectID, nvblnWithoutObjectID: false);
            bool         InternAddAcadObjectBlockEnd = default(bool);

            if (dobjAcadBlockEnd2 == null)
            {
                nrstrErrMsg = "Das Objekt konnte nicht hinzugefügt werden.";
            }
            else
            {
                AcadBlockEnd acadBlockEnd = dobjAcadBlockEnd2;
                acadBlockEnd.FriendLetIsPaperSpace = (vlngPaperSpace == 1);
                acadBlockEnd.Layer         = vstrLayer;
                acadBlockEnd.Linetype      = vstrLinetype;
                acadBlockEnd.Color         = (Enums.AcColor)vlngColor;
                acadBlockEnd.LinetypeScale = RuntimeHelpers.GetObjectValue(vvarLinetypeScale);
                acadBlockEnd.Visible       = (vlngVisible == 0);
                acadBlockEnd.FriendLetRGB  = vlngRGB;
                acadBlockEnd.Lineweight    = vnumLineweight;
                acadBlockEnd.FriendLetPlotStyleNameReference = vstrPlotStyleNameReference;
                acadBlockEnd.FriendSetDictReactors           = vobjDictReactors;
                acadBlockEnd = null;
                InternAddAcadObjectBlockEnd = true;
            }
            dobjAcadBlockEnd2 = null;
            return(InternAddAcadObjectBlockEnd);
        }
Пример #2
0
        private void InternListBlockEnd(AcadBlockEnd vobjAcadBlockEnd, ref int rlngIdx)
        {
            AcadBlockEnd acadBlockEnd = vobjAcadBlockEnd;

            InternAddToDictLine(ref rlngIdx, 0, "ENDBLK");
            InternAddToDictLine(ref rlngIdx, 5, acadBlockEnd.Handle);
            hwpDxf_List.BkDXFList_Reactors((Dictionary <object, object>)acadBlockEnd.DictReactors, ref rlngIdx, ref mobjDictReadCodes, ref mobjDictReadValues);
            InternAddToDictLine(ref rlngIdx, 330, acadBlockEnd.OwnerID);
            InternAddToDictLine(ref rlngIdx, 100, "AcDbEntity");
            if (acadBlockEnd.IsPaperSpace)
            {
                InternAddToDictLine(ref rlngIdx, 67, RuntimeHelpers.GetObjectValue(Interaction.IIf(acadBlockEnd.IsPaperSpace, 1, 0)));
            }
            InternAddToDictLine(ref rlngIdx, 8, acadBlockEnd.Layer);
            if (Operators.CompareString(acadBlockEnd.Linetype, hwpDxf_Vars.pstrEntityLinetype, TextCompare: false) != 0)
            {
                InternAddToDictLine(ref rlngIdx, 6, acadBlockEnd.Linetype);
            }
            if (acadBlockEnd.Color != hwpDxf_Vars.pnumEntityColor)
            {
                InternAddToDictLine(ref rlngIdx, 62, acadBlockEnd.Color);
            }
            if (Conversions.ToBoolean(Operators.OrObject(Operators.AndObject(false, Operators.CompareObjectNotEqual(acadBlockEnd.LinetypeScale, hwpDxf_Vars.pdecLinetypeScale, TextCompare: false)), Operators.AndObject(true, Operators.CompareObjectNotEqual(acadBlockEnd.LinetypeScale, hwpDxf_Vars.pdblLinetypeScale, TextCompare: false)))))
            {
                InternAddToDictLine(ref rlngIdx, 48, RuntimeHelpers.GetObjectValue(acadBlockEnd.LinetypeScale));
            }
            if ((double)acadBlockEnd.Lineweight != (double)hwpDxf_ConstMisc.pclngLineweight)
            {
                InternAddToDictLine(ref rlngIdx, 370, acadBlockEnd.Lineweight);
            }
            if (acadBlockEnd.PlotStyleNameObjectID != -1.0)
            {
                InternAddToDictLine(ref rlngIdx, Conversions.ToInteger("390"), acadBlockEnd.PlotStyleNameReference);
            }
            InternAddToDictLine(ref rlngIdx, 100, acadBlockEnd.ObjectName);
            acadBlockEnd = null;
        }