コード例 #1
0
 def next_id_fixture(self, request, slide_):
     used_ids, next_available_shape_id = request.param
     nvSpPr_bldr = an_nvSpPr()
     for used_id in used_ids:
         nvSpPr_bldr.with_child(a_cNvPr().with_id(used_id))
     spTree = an_spTree().with_nsdecls().with_child(nvSpPr_bldr).element
     print(spTree.xml)
     slide_.spTree = spTree
     shapes = BaseShapeTree(slide_)
     return shapes, next_available_shape_id
コード例 #2
0
ファイル: test_shapetree.py プロジェクト: lepy/python-pptx
 def len_fixture(self, slide):
     shapes = BaseShapeTree(slide)
     expected_count = 2
     return shapes, expected_count
コード例 #3
0
ファイル: test_shapetree.py プロジェクト: lepy/python-pptx
 def iter_elms_fixture(self, slide):
     shapes = BaseShapeTree(slide)
     expected_elm_count = 2
     return shapes, expected_elm_count
コード例 #4
0
ファイル: test_shapetree.py プロジェクト: lepy/python-pptx
 def iter_fixture(self, _iter_member_elms_, BaseShapeFactory_, sp_, sp_2_,
                  shape_, shape_2_):
     shapes = BaseShapeTree(None)
     return shapes, BaseShapeFactory_, sp_, sp_2_, shape_, shape_2_
コード例 #5
0
ファイル: test_shapetree.py プロジェクト: lepy/python-pptx
 def getitem_fixture(self, _iter_member_elms_, BaseShapeFactory_, sp_2_,
                     shape_):
     shapes = BaseShapeTree(None)
     idx = 1
     return shapes, idx, BaseShapeFactory_, sp_2_, shape_
コード例 #6
0
ファイル: test_shapetree.py プロジェクト: lepy/python-pptx
 def it_knows_the_part_it_belongs_to(self, slide):
     shapes = BaseShapeTree(slide)
     assert shapes.part is slide