private void method_6(Class537 A_0) { int num = 0; for (int i = 0; i < A_0.method_2().Length; i++) { switch (A_0.method_2()[i]) { case '\f': if ((this.subDocumentType_0 != SubDocumentType.Footnote) && (this.subDocumentType_0 != SubDocumentType.Endnote)) { Class17 class2 = this.class764_0.method_35(A_0.method_0(i + 1)); if (class2 != null) { Struct24 struct3 = this.method_8(A_0, num, i); num = i + 1; if (struct3.class1150_0.int_0 == 0) { this.method_9(A_0, i, struct3); if (this.class263_0.method_0() == ElementPostion.None) { this.class764_0.method_43().imethod_5(); this.class764_0.method_43().imethod_3(); this.int_1++; this.class764_0.method_43().imethod_2(class2); this.method_1(); this.class764_0.method_43().imethod_4(); } } } } break; case '\r': case '\a': if (this.method_7(A_0, i)) { Struct24 struct2 = this.method_8(A_0, num, i); num = i + 1; this.method_9(A_0, i, struct2); } break; } } if (num < A_0.method_2().Length) { this.class985_0.Add(new Class537(A_0, num, A_0.method_2().Length)); } }
private void method_9(Class537 A_0, int A_1, Struct24 A_2) { this.class263_0.method_2(A_2.class1150_0); if (A_2.class1150_0.method_1()) { int num = A_0.method_0(A_1); this.class132_0.method_2(num); this.class136_0.method_2(num); } else { this.method_10(A_2.paragraphFormat_0); } this.class263_0.method_3(A_2.class1150_0, A_2.rowFormat_0, this.class985_0.method_1().method_8()); this.class985_0.Clear(); }
private void method_4(int A_0, int A_1) { int num = this.class764_0.method_5().method_7(this.subDocumentType_0, A_0); this.method_5(num); int num2 = this.class764_0.method_6().method_1(num); if (num2 != -1) { int num4 = num - this.class764_0.method_6().method_4(num2).method_0().method_2(); int num3 = A_1; while (num3 > 0) { if (num2 >= this.class764_0.method_6().method_5()) { break; } Class602 class2 = this.class764_0.method_6().method_4(num2); int num5 = class2.int_0; int count = class2.method_0().method_6(); if (num4 > 0) { num5 += num4 * (class2.bool_0 ? 2 : 1); count -= num4; } this.class764_0.method_1().BaseStream.Position = num5; count = (count > num3) ? num3 : count; BinaryReader reader = class2.bool_0 ? this.class764_0.method_1() : this.class764_0.method_2(); Class537 class3 = new Class537(reader.ReadChars(count), new Class870(class2, num4), num5); this.method_6(class3); num3 -= count; num2++; num4 = 0; } if (this.class985_0.Count > 0) { Struct24 struct2 = new Struct24(new ParagraphFormat(), new Class1150(), new RowFormat(this.class764_0.method_42())); this.method_9(this.class985_0.method_0(0), 0, struct2); } } }
private IntPtr method_1(int snoRecordId) { try { byte[] bytes = BitConverter.GetBytes(snoRecordId); uint num = (uint)(bytes[3] ^ (0x1000193 * (bytes[2] ^ (0x1000193 * (bytes[1] ^ (0x1000193 * (bytes[0] ^ (0x1000193 * (snoRecordId ^ -2128831035))))))))); Struct15 native = this.Native; Struct25 struct3 = base.Memory.UnsafeReadToStruct <Struct25>(native.intptr_3); num &= struct3.uint_0; IntPtr address = base.Memory.UnsafeReadToStruct <IntPtr>(new IntPtr((uint)struct3.intptr_0 + (num * 4))); if (!(address != IntPtr.Zero)) { return(IntPtr.Zero); } Struct24 struct4 = base.Memory.UnsafeReadToStruct <Struct24>(address); while (struct4.uint_0 != snoRecordId) { if (struct4.intptr_0 == IntPtr.Zero) { return(IntPtr.Zero); } struct4 = base.Memory.UnsafeReadToStruct <Struct24>(struct4.intptr_0); } IntPtr[] addresses = new IntPtr[] { base.BaseAddress + 60, (IntPtr)0x148, (IntPtr)(0x10 * struct4.uint_1) }; IntPtr ptr2 = base.Memory.UnsafeReadPointersToStruct <IntPtr>(false, addresses); if (!(ptr2 != IntPtr.Zero)) { return(IntPtr.Zero); } return(ptr2); } catch { } return(IntPtr.Zero); }
public static extern bool GetClientRect(IntPtr hWnd, out Struct24 lpRect);
public static extern int MapWindowPoints(IntPtr hwndFrom, IntPtr hwndTo, ref Struct24 lpPoints, uint cPoints);
public static extern bool GetWindowRect(IntPtr hwnd, out Struct24 lpRect);
private static extern bool GetWindowInfo(IntPtr intptr_1, ref Struct24 struct24_0);
// Token: 0x06001E94 RID: 7828 RVA: 0x00063DB8 File Offset: 0x00061FB8 public unsafe void method_0() { try { Struct24 @struct = new Struct24(int.MaxValue, int.MaxValue, int.MinValue, int.MinValue); Struct24 struct2 = new Struct24(int.MaxValue, int.MaxValue, int.MinValue, int.MinValue); bool * ptr = stackalloc bool[(UIntPtr)(this.class95_0.rectangle_0.Height * this.class95_0.rectangle_0.Width)]; bool * ptr2 = stackalloc bool[(UIntPtr)(this.class95_0.rectangle_0.Height * this.class95_0.rectangle_0.Width)]; Struct24 *ptr3 = &@struct; Struct24 *ptr4 = &struct2; using (Class125 @class = new Class125(this.bitmap_0)) { using (new Class125.Class153(@class)) { Array[][] array = new Array[this.class95_0.array_0.Length][]; this.class95_0.array_0.CopyTo(array, 0); for (int i = 0; i < this.class95_0.rectangle_0.Height; i++) { Array[] array2 = array[i]; Array[] array3 = array2; int j = 0; while (j < array3.Length) { Array array4 = array3[j]; int k = array4.GetLowerBound(0); int length = array4.GetLength(0); int num = k + length - 1; bool flag = false; if (this.class95_0.bool_0) { Struct33[] array5 = new Struct33[length]; array4.CopyTo(array5, 0); try { Struct33[] array6; Struct33 * ptr5; if ((array6 = array5) != null && array6.Length != 0) { fixed(Struct33 *ptr5 = &array6[0]) { } } else { ptr5 = null; } Struct33 *ptr6 = ptr5; Struct33 *ptr7 = @class.pBase + @class.Width * i + k; bool * ptr8 = ptr + k + (IntPtr)this.class95_0.rectangle_0.Width * (IntPtr)i; while (k <= num) { if (ptr7->A != ptr6->A || ptr7->R != ptr6->R || ptr7->G != ptr6->G || ptr7->B != ptr6->B) { *ptr8 = true; flag = true; if (ptr3->int_0 > k) { ptr3->int_0 = k; } if (ptr3->int_2 < k) { ptr3->int_2 = k; } } ptr7++; ptr6++; ptr8++; k++; } goto IL_3B8; } finally { Struct33 *ptr5 = null; } goto IL_25F; } goto IL_25F; IL_395: j++; continue; IL_36D: if (ptr3->int_1 > i) { ptr3->int_1 = i; } if (ptr3->int_3 < i) { ptr3->int_3 = i; goto IL_395; } goto IL_395; IL_25F: Struct54[] array7 = new Struct54[length]; array4.CopyTo(array7, 0); try { Struct54[] array8; Struct54 * ptr9; if ((array8 = array7) != null && array8.Length != 0) { fixed(Struct54 *ptr9 = &array8[0]) { } } else { ptr9 = null; } Struct54 *ptr10 = ptr9; Struct33 *ptr11 = @class.pBase + @class.Width * i + k; bool * ptr12 = ptr + k + (IntPtr)this.class95_0.rectangle_0.Width * (IntPtr)i; while (k <= num) { if (ptr11->R != ptr10->R || ptr11->G != ptr10->G || ptr11->B != ptr10->B) { *ptr12 = true; flag = true; if (ptr3->int_0 > k) { ptr3->int_0 = k; } if (ptr3->int_2 < k) { ptr3->int_2 = k; } } ptr11++; ptr10++; ptr12++; k++; } goto IL_3B8; } finally { Struct54 *ptr9 = null; } goto IL_36D; IL_3B8: if (flag) { goto IL_36D; } goto IL_395; } if (this.cancellationToken_0.IsCancellationRequested) { return; } } } } for (int l = ptr3->int_1; l < ptr3->int_3; l++) { bool flag2 = false; bool *ptr13 = ptr + ptr3->int_0 + (IntPtr)l * (IntPtr)this.class95_0.rectangle_0.Width; bool *ptr14 = ptr2 + ptr3->int_0 + (IntPtr)l * (IntPtr)this.class95_0.rectangle_0.Width; for (int m = ptr3->int_0; m < ptr3->int_2; m++) { if (*ptr13 && (m + 1 == this.class95_0.rectangle_0.Width || ptr13[1]) && (m == 0 || *(ptr13 - 1)) && (l + 1 == this.class95_0.rectangle_0.Height || ptr13[this.class95_0.rectangle_0.Width]) && (l == 0 || *(ptr13 - this.class95_0.rectangle_0.Width))) { *ptr14 = true; flag2 = true; if (ptr4->int_0 > m) { ptr4->int_0 = m; } if (ptr4->int_2 < m) { ptr4->int_2 = m; } } ptr13++; ptr14++; } if (flag2) { if (ptr4->int_1 > l) { ptr4->int_1 = l; } if (ptr4->int_3 < l) { ptr4->int_3 = l; } } if (this.cancellationToken_0.IsCancellationRequested) { return; } } for (int n = ptr4->int_1; n < ptr4->int_3; n++) { bool *ptr15 = ptr2 + ptr4->int_0 + (IntPtr)n * (IntPtr)this.class95_0.rectangle_0.Width; for (int num2 = ptr4->int_0; num2 < ptr4->int_2; num2++) { if (*ptr15) { Struct24 struct3 = this.class95_0.method_9(ptr15, num2, n); struct3.int_2++; struct3.int_3++; Rectangle rectangle = struct3.method_0(); Size size = rectangle.Size; Class335.smethod_3(Class95 <ColorType> .string_1, new object[] { rectangle }); if (size.Width > this.size_0.Width && size.Height > this.size_0.Height && size.Width < this.size_1.Width && size.Height < this.size_1.Height) { bool flag3 = true; for (int num3 = rectangle.Y; num3 < rectangle.Bottom; num3++) { int[] array9 = this.class95_0.int_1[num3]; if (array9.Length > 0) { foreach (int num5 in array9) { if (num5 >= rectangle.Left && num5 <= rectangle.Right) { flag3 = false; break; } } } else { flag3 = false; } if (!flag3) { break; } if (this.cancellationToken_0.IsCancellationRequested) { return; } } if (flag3) { Rectangle rectangle2 = rectangle.smethod_4(this.class95_0.rectangle_0.X, this.class95_0.rectangle_0.Y); Class335.smethod_3(Class95 <ColorType> .string_0, new object[] { rectangle2 }); this.list_0.Add(rectangle2); } } for (int num6 = struct3.int_1; num6 < struct3.int_3; num6++) { bool *ptr16 = ptr2 + struct3.int_0 + (IntPtr)num6 * (IntPtr)this.class95_0.rectangle_0.Width; for (int num7 = struct3.int_0; num7 < struct3.int_2; num7++) { *ptr16 = false; ptr16++; } } } ptr15++; } if (this.cancellationToken_0.IsCancellationRequested) { break; } } } catch (Exception ex) { this.exception_0 = ex; } }
// Token: 0x06001E8E RID: 7822 RVA: 0x0006360C File Offset: 0x0006180C private unsafe Struct24 method_9(bool *start_pixel, int x_start, int y_start) { Struct24 result = new Struct24(x_start, y_start, x_start, y_start); Class95 <ColorType> .Enum60 @enum = Class95 <ColorType> .Enum60.const_0; Class95 <ColorType> .Enum60 enum2 = Class95 <ColorType> .Enum60.const_0; int num = x_start; int num2 = y_start; bool * ptr = start_pixel; Struct24 *ptr2 = &result; for (;;) { IL_279: if (num2 > 0 && *(ptr - this.rectangle_0.Width)) { num2--; ptr -= this.rectangle_0.Width; enum2 = Class95 <ColorType> .Enum60.const_3; if (ptr2->int_1 > num2) { ptr2->int_1 = num2; } } else if (num + 1 < this.rectangle_0.Width && ptr[1]) { num++; ptr++; if (ptr2->int_2 < num) { ptr2->int_2 = num; } } else { enum2 = Class95 <ColorType> .Enum60.const_2; } while (@enum != enum2 || start_pixel != ptr) { switch (enum2) { case Class95 <ColorType> .Enum60.const_0: goto IL_279; case Class95 <ColorType> .Enum60.const_1: if (num2 + 1 < this.rectangle_0.Height && ptr[this.rectangle_0.Width]) { num2++; ptr += this.rectangle_0.Width; enum2 = Class95 <ColorType> .Enum60.const_2; if (ptr2->int_3 < num2) { ptr2->int_3 = num2; } } else if (num > 0 && *(ptr - 1)) { num--; ptr--; if (ptr2->int_0 > num) { ptr2->int_0 = num; } } else { enum2 = Class95 <ColorType> .Enum60.const_3; } break; case Class95 <ColorType> .Enum60.const_2: if (num + 1 < this.rectangle_0.Width && ptr[1]) { num++; ptr++; enum2 = Class95 <ColorType> .Enum60.const_0; if (ptr2->int_2 < num) { ptr2->int_2 = num; } } else if (num2 + 1 < this.rectangle_0.Height && ptr[this.rectangle_0.Width]) { num2++; ptr += this.rectangle_0.Width; if (ptr2->int_3 < num2) { ptr2->int_3 = num2; } } else { enum2 = Class95 <ColorType> .Enum60.const_1; } break; case Class95 <ColorType> .Enum60.const_3: if (num > 0 && *(ptr - 1)) { num--; ptr--; enum2 = Class95 <ColorType> .Enum60.const_1; if (ptr2->int_0 > num) { ptr2->int_0 = num; } } else if (num2 > 0 && *(ptr - this.rectangle_0.Width)) { num2--; ptr -= this.rectangle_0.Width; if (ptr2->int_1 > num2) { ptr2->int_1 = num2; } } else { enum2 = Class95 <ColorType> .Enum60.const_0; } break; } } break; } return(result); }