spire-xls 15.7.1__py3-none-win_amd64.whl → 15.11.1__py3-none-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (88) hide show
  1. spire/xls/AddtionalFormatWrapper.py +18 -15
  2. spire/xls/CellRange.py +10 -8
  3. spire/xls/CellStyleFlag.py +7 -0
  4. spire/xls/CellStyleObject.py +19 -12
  5. spire/xls/CommentsRange.py +6 -17
  6. spire/xls/ConverterSetting.py +15 -0
  7. spire/xls/DocumentProperty.py +1 -1
  8. spire/xls/ExcelCommentObject.py +6 -1
  9. spire/xls/ExcelFont.py +21 -15
  10. spire/xls/ExcelGradient.py +2 -0
  11. spire/xls/ExcelInterior.py +0 -13
  12. spire/xls/ExportTableOptions.py +6 -0
  13. spire/xls/Font.py +103 -103
  14. spire/xls/FontWrapper.py +20 -18
  15. spire/xls/GradientStops.py +1 -1
  16. spire/xls/HPageBreak.py +1 -0
  17. spire/xls/HyperLink.py +1 -0
  18. spire/xls/MsoTextFrame.py +102 -0
  19. spire/xls/RangeRichTextString.py +2 -2
  20. spire/xls/ReferRangeArea.py +0 -8
  21. spire/xls/RichText.py +1 -1
  22. spire/xls/RichTextShape.py +2 -1
  23. spire/xls/RichTextString.py +1 -0
  24. spire/xls/ShapeGlow.py +1 -1
  25. spire/xls/TextSaveOptions.py +7 -0
  26. spire/xls/VPageBreak.py +1 -0
  27. spire/xls/Workbook.py +85 -86
  28. spire/xls/Worksheet.py +63 -12
  29. spire/xls/XlsAddInFunction.py +4 -4
  30. spire/xls/XlsArcShape.py +1 -1
  31. spire/xls/XlsBorder.py +1 -0
  32. spire/xls/XlsButtonShape.py +1 -1
  33. spire/xls/XlsComment.py +1 -1
  34. spire/xls/XlsDataValidationTable.py +3 -1
  35. spire/xls/XlsFont.py +20 -14
  36. spire/xls/XlsName.py +14 -15
  37. spire/xls/XlsOvalShape.py +1 -1
  38. spire/xls/XlsPageSetup.py +8 -2
  39. spire/xls/XlsRadioButtonShape.py +21 -51
  40. spire/xls/XlsRange.py +26 -10
  41. spire/xls/XlsRectangleShape.py +1 -1
  42. spire/xls/XlsShape.py +7 -5
  43. spire/xls/XlsShapeFill.py +3 -0
  44. spire/xls/XlsStyle.py +3 -3
  45. spire/xls/XlsValidation.py +7 -4
  46. spire/xls/XlsWorkbook.py +50 -29
  47. spire/xls/XlsWorksheet.py +118 -121
  48. spire/xls/XlsWorksheetBase.py +39 -20
  49. spire/xls/__init__.py +2 -1
  50. spire/xls/autofilter/AutoFitterOptions.py +7 -0
  51. spire/xls/autofilter/CustomFilter.py +9 -1
  52. spire/xls/autofilter/FilterColumn.py +2 -2
  53. spire/xls/autofilter/XlsAutoFiltersCollection.py +1 -0
  54. spire/xls/charts/ChartArea.py +1 -0
  55. spire/xls/charts/XlsChart.py +1 -1
  56. spire/xls/charts/XlsChartFrameFormat.py +2 -1
  57. spire/xls/collection/ArcShapeCollection.py +1 -1
  58. spire/xls/collection/AutoFiltersCollection.py +1 -0
  59. spire/xls/collection/BordersCollectionArrayWrapper.py +2 -2
  60. spire/xls/collection/ButtonShapeCollection.py +4 -4
  61. spire/xls/collection/DataConnections.py +1 -1
  62. spire/xls/collection/ExternalLinkCollection.py +2 -1
  63. spire/xls/collection/GroupBoxCollection.py +4 -4
  64. spire/xls/collection/QueryTableCollection.py +1 -1
  65. spire/xls/collection/RangesCollection.py +4 -3
  66. spire/xls/collection/ShapeCollectionBase.py +6 -6
  67. spire/xls/collection/WorksheetsCollection.py +6 -6
  68. spire/xls/collection/XlsBordersCollection.py +2 -2
  69. spire/xls/collection/XlsChartsCollection.py +10 -8
  70. spire/xls/collection/XlsDataValidationCollection.py +4 -2
  71. spire/xls/collection/XlsFontsCollection.py +2 -1
  72. spire/xls/collection/XlsRangesCollection.py +17 -10
  73. spire/xls/collection/XlsStylesCollection.py +2 -2
  74. spire/xls/collection/XlsWorkbookObjectsCollection.py +5 -4
  75. spire/xls/collection/pivot_table/XlsPivotCachesCollection.py +1 -0
  76. spire/xls/collection/pivot_table/XlsPivotTablesCollection.py +1 -0
  77. spire/xls/conditional_formatting/ConditionalFormatWrapper.py +2 -2
  78. spire/xls/conditional_formatting/XlsConditionalFormat.py +10 -2
  79. spire/xls/conditional_formatting/XlsConditionalFormats.py +10 -5
  80. spire/xls/interfaces/IWorksheet.py +10 -10
  81. spire/xls/interfaces/ImportObjectOptions.py +7 -0
  82. spire/xls/lib/Spire.Xls.Base.dll +0 -0
  83. spire/xls/pivot_tables/PivotStyle.py +1 -0
  84. spire/xls/pivot_tables/PivotTableStyle.py +19 -12
  85. {spire_xls-15.7.1.dist-info → spire_xls-15.11.1.dist-info}/METADATA +1 -1
  86. {spire_xls-15.7.1.dist-info → spire_xls-15.11.1.dist-info}/RECORD +88 -87
  87. {spire_xls-15.7.1.dist-info → spire_xls-15.11.1.dist-info}/WHEEL +0 -0
  88. {spire_xls-15.7.1.dist-info → spire_xls-15.11.1.dist-info}/top_level.txt +0 -0
@@ -76,6 +76,7 @@ class AddtionalFormatWrapper ( CommonWrapper, IInternalAddtionalFormat, IExtend
76
76
  Returns:
77
77
  XlsWorkbook: The workbook object that contains this format.
78
78
  """
79
+ from spire.xls import XlsWorkbook
79
80
  GetDllLibXls().AddtionalFormatWrapper_get_Workbook.argtypes=[c_void_p]
80
81
  GetDllLibXls().AddtionalFormatWrapper_get_Workbook.restype=c_void_p
81
82
  intPtr = CallCFunction(GetDllLibXls().AddtionalFormatWrapper_get_Workbook, self.Ptr)
@@ -680,19 +681,19 @@ class AddtionalFormatWrapper ( CommonWrapper, IInternalAddtionalFormat, IExtend
680
681
  GetDllLibXls().AddtionalFormatWrapper_set_NumberFormatLocal.argtypes=[c_void_p, c_wchar_p]
681
682
  CallCFunction(GetDllLibXls().AddtionalFormatWrapper_set_NumberFormatLocal, self.Ptr, value)
682
683
 
683
- #@property
684
+ @property
684
685
 
685
- #def NumberFormatSettings(self)->'INumberFormat':
686
- # """
687
- #<summary>
688
- # Returns object that describes number format. Read-only.
689
- #</summary>
690
- # """
691
- # GetDllLibXls().AddtionalFormatWrapper_get_NumberFormatSettings.argtypes=[c_void_p]
692
- # GetDllLibXls().AddtionalFormatWrapper_get_NumberFormatSettings.restype=c_void_p
693
- # intPtr = CallCFunction(GetDllLibXls().AddtionalFormatWrapper_get_NumberFormatSettings, self.Ptr)
694
- # ret = None if intPtr==None else INumberFormat(intPtr)
695
- # return ret
686
+ def NumberFormatSettings(self)->'INumberFormat':
687
+ """
688
+ <summary>
689
+ Returns object that describes number format. Read-only.
690
+ </summary>
691
+ """
692
+ GetDllLibXls().AddtionalFormatWrapper_get_NumberFormatSettings.argtypes=[c_void_p]
693
+ GetDllLibXls().AddtionalFormatWrapper_get_NumberFormatSettings.restype=c_void_p
694
+ intPtr = CallCFunction(GetDllLibXls().AddtionalFormatWrapper_get_NumberFormatSettings, self.Ptr)
695
+ ret = None if intPtr==None else INumberFormat(intPtr)
696
+ return ret
696
697
 
697
698
 
698
699
  @property
@@ -785,10 +786,11 @@ class AddtionalFormatWrapper ( CommonWrapper, IInternalAddtionalFormat, IExtend
785
786
  """
786
787
 
787
788
  """
789
+ from spire.xls.FontWrapper import FontWrapper
788
790
  GetDllLibXls().AddtionalFormatWrapper_get_Font.argtypes=[c_void_p]
789
791
  GetDllLibXls().AddtionalFormatWrapper_get_Font.restype=c_void_p
790
792
  intPtr = CallCFunction(GetDllLibXls().AddtionalFormatWrapper_get_Font, self.Ptr)
791
- ret = None if intPtr==None else XlsFont(intPtr)
793
+ ret = None if intPtr==None else FontWrapper(intPtr)
792
794
  return ret
793
795
 
794
796
 
@@ -798,6 +800,7 @@ class AddtionalFormatWrapper ( CommonWrapper, IInternalAddtionalFormat, IExtend
798
800
  """
799
801
 
800
802
  """
803
+ from spire.xls.collection.XlsBordersCollection import XlsBordersCollection
801
804
  GetDllLibXls().AddtionalFormatWrapper_get_Borders.argtypes=[c_void_p]
802
805
  GetDllLibXls().AddtionalFormatWrapper_get_Borders.restype=c_void_p
803
806
  intPtr = CallCFunction(GetDllLibXls().AddtionalFormatWrapper_get_Borders, self.Ptr)
@@ -937,7 +940,7 @@ class AddtionalFormatWrapper ( CommonWrapper, IInternalAddtionalFormat, IExtend
937
940
  CallCFunction(GetDllLibXls().AddtionalFormatWrapper_EndUpdate, self.Ptr)
938
941
 
939
942
 
940
- def Clone(self ,parent:'SpireObject')->'SpireObject':
943
+ def Clone(self ,parent:'SpireObject')->'AddtionalFormatWrapper':
941
944
  """Creates a copy of the current formatting with the specified parent.
942
945
 
943
946
  Args:
@@ -951,7 +954,7 @@ class AddtionalFormatWrapper ( CommonWrapper, IInternalAddtionalFormat, IExtend
951
954
  GetDllLibXls().AddtionalFormatWrapper_Clone.argtypes=[c_void_p ,c_void_p]
952
955
  GetDllLibXls().AddtionalFormatWrapper_Clone.restype=c_void_p
953
956
  intPtr = CallCFunction(GetDllLibXls().AddtionalFormatWrapper_Clone, self.Ptr, intPtrparent)
954
- ret = None if intPtr==None else SpireObject(intPtr)
957
+ ret = None if intPtr==None else AddtionalFormatWrapper(intPtr)
955
958
  return ret
956
959
 
957
960
 
spire/xls/CellRange.py CHANGED
@@ -803,6 +803,7 @@ class CellRange ( XlsRange) :
803
803
  Returns a worksheet object that represents the worksheet containing the specified range.
804
804
 
805
805
  """
806
+ from spire.xls.Worksheet import Worksheet
806
807
  GetDllLibXls().CellRange_get_Worksheet.argtypes=[c_void_p]
807
808
  GetDllLibXls().CellRange_get_Worksheet.restype=c_void_p
808
809
  intPtr = CallCFunction(GetDllLibXls().CellRange_get_Worksheet, self.Ptr)
@@ -908,27 +909,28 @@ class CellRange ( XlsRange) :
908
909
 
909
910
 
910
911
 
911
- def GetDependentRanges(self ,isAll:bool)->'ListCellRanges':
912
+ def GetDependentRanges(self ,isAll:bool)->List['CellRange']:
912
913
  """
913
914
 
914
915
  """
915
916
 
916
917
  GetDllLibXls().CellRange_GetDependentRanges.argtypes=[c_void_p ,c_bool]
917
- GetDllLibXls().CellRange_GetDependentRanges.restype=c_void_p
918
- intPtr = CallCFunction(GetDllLibXls().CellRange_GetDependentRanges, self.Ptr, isAll)
919
- ret = None if intPtr==None else ListCellRanges(intPtr)
918
+ GetDllLibXls().CellRange_GetDependentRanges.restype=IntPtrArray
919
+ intPtrArray = CallCFunction(GetDllLibXls().CellRange_GetDependentRanges, self.Ptr, isAll)
920
+ ret = GetObjVectorFromArray(intPtrArray, CellRange)
920
921
  return ret
921
922
 
922
923
 
923
924
 
924
- def GetReferRanges(self)->'ListReferRangeAreas':
925
+ def GetReferRanges(self)->List['ReferRangeArea']:
925
926
  """
926
927
 
927
928
  """
929
+ from spire.xls.ReferRangeArea import ReferRangeArea
928
930
  GetDllLibXls().CellRange_GetReferRanges.argtypes=[c_void_p]
929
- GetDllLibXls().CellRange_GetReferRanges.restype=c_void_p
930
- intPtr = CallCFunction(GetDllLibXls().CellRange_GetReferRanges, self.Ptr)
931
- ret = None if intPtr==None else ListReferRangeAreas(intPtr)
931
+ GetDllLibXls().CellRange_GetReferRanges.restype=IntPtrArray
932
+ intPtrArray = CallCFunction(GetDllLibXls().CellRange_GetReferRanges, self.Ptr)
933
+ ret = GetObjVectorFromArray(intPtrArray, ReferRangeArea)
932
934
  return ret
933
935
 
934
936
 
@@ -14,6 +14,13 @@ class CellStyleFlag (SpireObject) :
14
14
  when applying styles to ranges. Each property corresponds to a specific formatting
15
15
  aspect such as borders, font properties, alignment, etc.
16
16
  """
17
+
18
+ def __init__(self):
19
+ GetDllLibXls().CellStyleFlag_Create.restype = c_void_p
20
+ intPtr = CallCFunction(GetDllLibXls().CellStyleFlag_Create)
21
+
22
+ super(CellStyleFlag,self).__init__(intPtr)
23
+
17
24
  @property
18
25
  def All(self)->bool:
19
26
  """Gets or sets whether all style elements should be applied.
@@ -50,6 +50,7 @@ class CellStyleObject ( SpireObject, IStyle) :
50
50
  """
51
51
 
52
52
  """
53
+ from spire.xls import ExcelInterior
53
54
  GetDllLibXls().CellStyleObject_get_Interior.argtypes=[c_void_p]
54
55
  GetDllLibXls().CellStyleObject_get_Interior.restype=c_void_p
55
56
  intPtr = CallCFunction(GetDllLibXls().CellStyleObject_get_Interior, self.Ptr)
@@ -82,18 +83,23 @@ class CellStyleObject ( SpireObject, IStyle) :
82
83
  GetDllLibXls().CellStyleObject_SetThemeColor.argtypes=[c_void_p ,c_int,c_double]
83
84
  CallCFunction(GetDllLibXls().CellStyleObject_SetThemeColor, self.Ptr, enumtype,tint)
84
85
 
85
- #
86
- # def GetThemeColor(self ,type:'ThemeColorType&',tint:'Double&')->bool:
87
- # """
88
- #
89
- # """
90
- # intPtrtype:c_void_p = type.Ptr
91
- # intPtrtint:c_void_p = tint.Ptr
92
- #
93
- # GetDllLibXls().CellStyleObject_GetThemeColor.argtypes=[c_void_p ,c_void_p,c_void_p]
94
- # GetDllLibXls().CellStyleObject_GetThemeColor.restype=c_bool
95
- # ret = CallCFunction(GetDllLibXls().CellStyleObject_GetThemeColor, self.Ptr, intPtrtype,intPtrtint)
96
- # return ret
86
+ def GetThemeColor(self)->Tuple[bool,ThemeColorType,float]:
87
+
88
+ GetDllLibXls().CellStyleObject_GetThemeColor_bool.argtypes=[c_void_p ]
89
+ GetDllLibXls().CellStyleObject_GetThemeColor_bool.restype=c_bool
90
+ ret = CallCFunction(GetDllLibXls().CellStyleObject_GetThemeColor_bool, self.Ptr)
91
+ if not ret:
92
+ return False,None,None
93
+ GetDllLibXls().CellStyleObject_GetThemeColor_Type.argtypes=[c_void_p ]
94
+ GetDllLibXls().CellStyleObject_GetThemeColor_Type.restype=c_int
95
+ ret_type = CallCFunction(GetDllLibXls().CellStyleObject_GetThemeColor_Type, self.Ptr)
96
+ theme_type = None if ret_type is None else ThemeColorType(ret_type)
97
+
98
+ GetDllLibXls().CellStyleObject_GetThemeColor_Tint.argtypes=[c_void_p ]
99
+ GetDllLibXls().CellStyleObject_GetThemeColor_Tint.restype=c_double
100
+ theme_tint = CallCFunction(GetDllLibXls().CellStyleObject_GetThemeColor_Tint, self.Ptr)
101
+
102
+ return True,theme_type,theme_tint
97
103
 
98
104
 
99
105
  @property
@@ -102,6 +108,7 @@ class CellStyleObject ( SpireObject, IStyle) :
102
108
  """
103
109
 
104
110
  """
111
+ from spire.xls.collection.XlsBordersCollection import XlsBordersCollection
105
112
  GetDllLibXls().CellStyleObject_get_Borders.argtypes=[c_void_p]
106
113
  GetDllLibXls().CellStyleObject_get_Borders.restype=c_void_p
107
114
  intPtr = CallCFunction(GetDllLibXls().CellStyleObject_get_Borders, self.Ptr)
@@ -85,7 +85,7 @@ class CommentsRange ( XlsObject, IComment, ITextBoxShape, ITextBox, IShape) :
85
85
  GetDllLibXls().CommentsRange_get_RichText.argtypes=[c_void_p]
86
86
  GetDllLibXls().CommentsRange_get_RichText.restype=c_void_p
87
87
  intPtr = CallCFunction(GetDllLibXls().CommentsRange_get_RichText, self.Ptr)
88
- ret = None if intPtr==None else RichTextObject(intPtr)
88
+ ret = None if intPtr==None else RTFCommentArray(intPtr)
89
89
  return ret
90
90
 
91
91
 
@@ -341,10 +341,10 @@ class CommentsRange ( XlsObject, IComment, ITextBoxShape, ITextBox, IShape) :
341
341
  objwraped = ExcelShapeType(ret)
342
342
  return objwraped
343
343
 
344
- @ShapeType.setter
345
- def ShapeType(self, value:'ExcelShapeType'):
346
- GetDllLibXls().CommentsRange_set_ShapeType.argtypes=[c_void_p, c_int]
347
- CallCFunction(GetDllLibXls().CommentsRange_set_ShapeType, self.Ptr, value.value)
344
+ # @ShapeType.setter
345
+ # def ShapeType(self, value:'ExcelShapeType'):
346
+ # GetDllLibXls().CommentsRange_set_ShapeType.argtypes=[c_void_p, c_int]
347
+ # CallCFunction(GetDllLibXls().CommentsRange_set_ShapeType, self.Ptr, value.value)
348
348
 
349
349
  @property
350
350
 
@@ -388,18 +388,7 @@ class CommentsRange ( XlsObject, IComment, ITextBoxShape, ITextBox, IShape) :
388
388
  @property
389
389
 
390
390
  def Fill(self)->'IShapeFill':
391
- """Gets the fill formatting for the comment shape.
392
-
393
- The fill formatting includes properties such as fill color, pattern, and gradient.
394
-
395
- Returns:
396
- IShapeFill: The fill formatting object for the comment shape.
397
- """
398
- GetDllLibXls().CommentsRange_get_Fill.argtypes=[c_void_p]
399
- GetDllLibXls().CommentsRange_get_Fill.restype=c_void_p
400
- intPtr = CallCFunction(GetDllLibXls().CommentsRange_get_Fill, self.Ptr)
401
- ret = None if intPtr==None else XlsShapeFill(intPtr)
402
- return ret
391
+ raise NotImplementedError()
403
392
 
404
393
 
405
394
  @property
@@ -32,6 +32,21 @@ class ConverterSetting (SpireObject) :
32
32
  # return ret
33
33
  #
34
34
 
35
+ _correct_names = {
36
+ 'xdpi': 'XDpi',
37
+ 'ydpi': 'YDpi',
38
+ }
39
+
40
+ def __setattr__(self, name: str, value):
41
+ lower_name = name.lower()
42
+ if lower_name in self._correct_names and name != self._correct_names[lower_name]:
43
+ correct_name = self._correct_names[lower_name]
44
+ raise AttributeError(
45
+ f"'{type(self).__name__}' object has no attribute '{name}'. "
46
+ f"Did you mean '{correct_name}'?"
47
+ )
48
+ else:
49
+ super().__setattr__(name, value)
35
50
 
36
51
  @property
37
52
  def XDpi(self)->int:
@@ -36,7 +36,7 @@ class DocumentProperty ( SpireObject, IDocumentProperty) :
36
36
  GetDllLibXls().DocumentProperty_get_PropertyId.argtypes=[c_void_p]
37
37
  GetDllLibXls().DocumentProperty_get_PropertyId.restype=c_int
38
38
  ret = CallCFunction(GetDllLibXls().DocumentProperty_get_PropertyId, self.Ptr)
39
- objwraped = BuiltInPropertyType(ret)
39
+ objwraped = BuiltInPropertyType(ret) if ret >0 else None
40
40
  return objwraped
41
41
 
42
42
  @property
@@ -129,6 +129,7 @@ class ExcelCommentObject ( SpireObject, IComment) :
129
129
  Returns:
130
130
  IShapeLineFormat: The line formatting object for the comment shape border.
131
131
  """
132
+ from spire.xls.XlsShapeLineFormat import XlsShapeLineFormat
132
133
  GetDllLibXls().ExcelCommentObject_get_Line.argtypes=[c_void_p]
133
134
  GetDllLibXls().ExcelCommentObject_get_Line.restype=c_void_p
134
135
  intPtr = CallCFunction(GetDllLibXls().ExcelCommentObject_get_Line, self.Ptr)
@@ -201,10 +202,11 @@ class ExcelCommentObject ( SpireObject, IComment) :
201
202
  Returns:
202
203
  ITextFrame: The text frame object for the comment shape.
203
204
  """
205
+ from spire.xls.MsoTextFrame import MsoTextFrame
204
206
  GetDllLibXls().ExcelCommentObject_get_TextFrame.argtypes=[c_void_p]
205
207
  GetDllLibXls().ExcelCommentObject_get_TextFrame.restype=c_void_p
206
208
  intPtr = CallCFunction(GetDllLibXls().ExcelCommentObject_get_TextFrame, self.Ptr)
207
- ret = None if intPtr==None else ITextFrame(intPtr)
209
+ ret = None if intPtr==None else MsoTextFrame(intPtr)
208
210
  return ret
209
211
 
210
212
 
@@ -592,6 +594,7 @@ class ExcelCommentObject ( SpireObject, IComment) :
592
594
  Returns:
593
595
  IGlow: The glow effect formatting object for the comment shape.
594
596
  """
597
+ from spire.xls.ShapeGlow import ShapeGlow
595
598
  GetDllLibXls().ExcelCommentObject_get_Glow.argtypes=[c_void_p]
596
599
  GetDllLibXls().ExcelCommentObject_get_Glow.restype=c_void_p
597
600
  intPtr = CallCFunction(GetDllLibXls().ExcelCommentObject_get_Glow, self.Ptr)
@@ -609,6 +612,7 @@ class ExcelCommentObject ( SpireObject, IComment) :
609
612
  Returns:
610
613
  IReflectionEffect: The reflection effect formatting object for the comment shape.
611
614
  """
615
+ from spire.xls.ShapeReflection import ShapeReflection
612
616
  GetDllLibXls().ExcelCommentObject_get_Reflection.argtypes=[c_void_p]
613
617
  GetDllLibXls().ExcelCommentObject_get_Reflection.restype=c_void_p
614
618
  intPtr = CallCFunction(GetDllLibXls().ExcelCommentObject_get_Reflection, self.Ptr)
@@ -626,6 +630,7 @@ class ExcelCommentObject ( SpireObject, IComment) :
626
630
  Returns:
627
631
  IFormat3D: The 3D formatting object for the comment shape.
628
632
  """
633
+ from spire.xls.Format3D import Format3D
629
634
  GetDllLibXls().ExcelCommentObject_get_ThreeD.argtypes=[c_void_p]
630
635
  GetDllLibXls().ExcelCommentObject_get_ThreeD.restype=c_void_p
631
636
  intPtr = CallCFunction(GetDllLibXls().ExcelCommentObject_get_ThreeD, self.Ptr)
spire/xls/ExcelFont.py CHANGED
@@ -70,31 +70,37 @@ class ExcelFont ( SpireObject, IFont) :
70
70
  CallCFunction(GetDllLibXls().ExcelFont_set_Color, self.Ptr, value.Ptr)
71
71
 
72
72
 
73
- def SetThemeColor(self ,type:'ThemeColorType',tint:float):
73
+ def SetThemeColor(self ,theme_type:'ThemeColorType',tint:float):
74
74
  """Sets the theme color for the font.
75
75
 
76
76
  Args:
77
- type (ThemeColorType): The theme color type to apply.
77
+ theme_type (ThemeColorType): The theme color type to apply.
78
78
  tint (float): The tint value to apply to the theme color, between -1.0 and 1.0.
79
79
  Positive values lighten the color, negative values darken it.
80
80
  """
81
- enumtype:c_int = type.value
81
+ enumtype:c_int = theme_type.value
82
82
 
83
83
  GetDllLibXls().ExcelFont_SetThemeColor.argtypes=[c_void_p ,c_int,c_double]
84
84
  CallCFunction(GetDllLibXls().ExcelFont_SetThemeColor, self.Ptr, enumtype,tint)
85
85
 
86
- #
87
- # def GetThemeColor(self ,type:'ThemeColorType&',tint:'Double&')->bool:
88
- # """
89
- #
90
- # """
91
- # intPtrtype:c_void_p = type.Ptr
92
- # intPtrtint:c_void_p = tint.Ptr
93
- #
94
- # GetDllLibXls().ExcelFont_GetThemeColor.argtypes=[c_void_p ,c_void_p,c_void_p]
95
- # GetDllLibXls().ExcelFont_GetThemeColor.restype=c_bool
96
- # ret = CallCFunction(GetDllLibXls().ExcelFont_GetThemeColor, self.Ptr, intPtrtype,intPtrtint)
97
- # return ret
86
+
87
+ def GetThemeColor(self)->Tuple[bool,ThemeColorType,float]:
88
+
89
+ GetDllLibXls().ExcelFont_GetThemeColor_bool.argtypes=[c_void_p ]
90
+ GetDllLibXls().ExcelFont_GetThemeColor_bool.restype=c_bool
91
+ ret = CallCFunction(GetDllLibXls().ExcelFont_GetThemeColor_bool, self.Ptr)
92
+ if not ret:
93
+ return False,None,None
94
+ GetDllLibXls().ExcelFont_GetThemeColor_Type.argtypes=[c_void_p ]
95
+ GetDllLibXls().ExcelFont_GetThemeColor_Type.restype=c_void_p
96
+ ret_type = CallCFunction(GetDllLibXls().ExcelFont_GetThemeColor_Type, self.Ptr)
97
+ theme_type = None if ret_type is None else ThemeColorType(ret_type)
98
+
99
+ GetDllLibXls().ExcelFont_GetThemeColor_Tint.argtypes=[c_void_p ]
100
+ GetDllLibXls().ExcelFont_GetThemeColor_Tint.restype=c_double
101
+ theme_tint = CallCFunction(GetDllLibXls().ExcelFont_GetThemeColor_Tint, self.Ptr)
102
+
103
+ return True,theme_type,theme_tint
98
104
 
99
105
 
100
106
  @property
@@ -41,6 +41,7 @@ class ExcelGradient ( SpireObject, IGradient) :
41
41
  Returns:
42
42
  OColor: An OColor object representing the ending color of the gradient.
43
43
  """
44
+ from spire.xls.OColor import OColor
44
45
  GetDllLibXls().ExcelGradient_get_BackColorObject.argtypes=[c_void_p]
45
46
  GetDllLibXls().ExcelGradient_get_BackColorObject.restype=c_void_p
46
47
  intPtr = CallCFunction(GetDllLibXls().ExcelGradient_get_BackColorObject, self.Ptr)
@@ -114,6 +115,7 @@ class ExcelGradient ( SpireObject, IGradient) :
114
115
  Returns:
115
116
  OColor: An OColor object representing the starting color of the gradient.
116
117
  """
118
+ from spire.xls.OColor import OColor
117
119
  GetDllLibXls().ExcelGradient_get_ForeColorObject.argtypes=[c_void_p]
118
120
  GetDllLibXls().ExcelGradient_get_ForeColorObject.restype=c_void_p
119
121
  intPtr = CallCFunction(GetDllLibXls().ExcelGradient_get_ForeColorObject, self.Ptr)
@@ -140,18 +140,5 @@ class ExcelInterior ( SpireObject, IInterior) :
140
140
  CallCFunction(GetDllLibXls().ExcelInterior_set_FillPattern, self.Ptr, value.value)
141
141
 
142
142
 
143
- def m_interior(self)->'IInterior':
144
- """Gets the internal IInterior interface implementation.
145
-
146
- This method is primarily used internally to access the underlying interior object.
147
-
148
- Returns:
149
- IInterior: The internal IInterior interface implementation.
150
- """
151
- GetDllLibXls().ExcelInterior_m_interior.argtypes=[c_void_p]
152
- GetDllLibXls().ExcelInterior_m_interior.restype=c_void_p
153
- intPtr = CallCFunction(GetDllLibXls().ExcelInterior_m_interior, self.Ptr)
154
- ret = None if intPtr==None else ExcelInterior(intPtr)
155
- return ret
156
143
 
157
144
 
@@ -13,6 +13,12 @@ class ExportTableOptions (SpireObject) :
13
13
  to other formats such as DataTable, CSV, etc. It allows customization of data formatting,
14
14
  column names handling, and formula calculation during the export process.
15
15
  """
16
+ @dispatch
17
+ def __init__(self):
18
+ GetDllLibXls().ExportTableOptions_Create.restype = c_void_p
19
+ intPtr = CallCFunction(GetDllLibXls().ExportTableOptions_Create)
20
+ super(ExportTableOptions, self).__init__(intPtr)
21
+
16
22
  @property
17
23
  def KeepDataFormat(self)->bool:
18
24
  """Gets or sets whether to keep the original data format when exporting.