yuuho.wiki

カオスの欠片を集めて知恵の泉を作る

ユーザ用ツール

サイト用ツール


tips:python:pptx:start

差分

このページの2つのバージョン間の差分を表示します。

この比較画面へのリンク

両方とも前のリビジョン前のリビジョン
次のリビジョン
前のリビジョン
tips:python:pptx:start [2021/09/08 00:58] – [はじめに] yuuhotips:python:pptx:start [2021/09/08 03:13] (現在) – [はじめに] yuuho
行 1: 行 1:
 ====== python-pptx ====== ====== python-pptx ======
 +=== リンク ===
   * [[https://python-pptx.readthedocs.io/en/latest/|公式ドキュメント]]   * [[https://python-pptx.readthedocs.io/en/latest/|公式ドキュメント]]
  
行 5: 行 6:
 ===== はじめに ===== ===== はじめに =====
  
-メインは Presentation クラス。  +メインは Presentation クラス。 
 +  * ''pptx.Presentation()'' -> %%<%%Presentation%%>%% 
 +    * ''core_properties'' -> %%<%%CorePropertiesPart%%>%% 
 +    * ''slides'' -> %%<%%Slides%%>%% 
 +      * ''[i]'' -> %%<%%Slide%%>%% 
 +    * ''slide_masters'' -> %%<%%SlideMasters%%>%% 
 +      * ''[i]'' -> %%<%%SlideMaster%%>%% 
 +    * ''slide_layouts'' -> %%<%%SlideLayouts%%>%% 
 +      * ''[i]'' -> %%<%%SlideLayout%%>%% 
 +    * ''slide_master'' -> %%<%%SlideMaster%%>%% = ''slide_masters[0]''
  
 +  * ''pptx.Presentation().slides[i]'' -> %%<%%Slide%%>%%
 +    * ''shapes'' -> %%<%%SlideShapes%%>%%
 +      * ''[i]'' -> 何らか\\ ''pptx.shapes.placeholder.SlideSPlaceholder''\\ or ''pptx.shapes.autoshape.Shape'' or etc.
 +
 +Util にはインチ/cm/pt を powerpoint内単位の長さに変換する関数などがある。
 +  * ''pptx''
 +    * ''Inches''
 +    * ''Cm''
 +    * ''Pt''
 +
 +  * 色のオブジェクト ''pptx.dml.color.RGBColor''
 +  * 形状のオブジェクト一覧 ''pptx.enum.shapes.MSO_SHAPE''
 +  * 線のスタイル一覧 ''pptx.enum.shapes.MSO_CONNECTOR_TYPE''
 +  * 色のテーマ ''pptx.enum.dml.MSO_THEME_COLOR''
 +
 +
 +===== 形状 =====
 +  * ''OVAL'' : 円/楕円形
 +  * ''RECTANGLE'' : 矩形
 +  * ''ROUNDED_RECTANGLE'' : 角丸矩形
  
-Presentation 
-  *  
  
 ===== メモ ===== ===== メモ =====
行 28: 行 56:
     (- _element - _part - _slide_masters - _slides)     (- _element - _part - _slide_masters - _slides)
  
 +# pptxファイルの設定
 CorePropertiesPart CorePropertiesPart
     - after_unmarshal     - after_unmarshal
行 93: 行 122:
     - remove     - remove
  
-現在有効なスライドマスターのこと? +# スライドレイアウト 
-SlideMaster+SlideLayout
     - background     - background
     - element     - element
 +    - iter_cloneable_placeholders
     - name     - name
     - part     - part
     - placeholders     - placeholders
     - shapes     - shapes
-    - slide_layouts+    - slide_master 
 +    - used_by_slides
  
 # 複数あるスライドマスターの一覧、先頭にあるのが有効なスライドマスターとなる? # 複数あるスライドマスターの一覧、先頭にあるのが有効なスライドマスターとなる?
行 110: 行 141:
     - [0] : SlideMaster     - [0] : SlideMaster
  
 +# 現在有効なスライドマスターのこと?
 +SlideMaster
 +    - background
 +    - element
 +    - name
 +    - part
 +    - placeholders
 +    - shapes
 +    - slide_layouts
 +</code>
  
 +
 +<code>
 # 図形 # 図形
 Shape Shape
-    - +    - adjustments 
 +    - auto_shape_type 
 +    - click_action 
 +    - element 
 +    - fill 
 +    - get_or_add_ln 
 +    - has_chart 
 +    - has_table 
 +    - has_text_frame 
 +    - height 
 +    - is_placeholder 
 +    - left 
 +    - line 
 +    - ln 
 +    - name 
 +    - part 
 +    - placeholder_format 
 +    - rotation 
 +    - shadow 
 +    - shape_id 
 +    - shape_type 
 +    - text 
 +    - text_frame 
 +    - top 
 +    - width
 </code> </code>
  
 +
 +<code>
 +MSO_SHAPE
 +
 +    - from_xml
 +    - to_xml
 +    - validate
 +</code>
tips/python/pptx/start.1631062688.txt.gz · 最終更新: 2021/09/08 00:58 by yuuho