;ELC ;;; Compiled ;;; in Emacs version 28.0.50 ;;; with all optimizations. (byte-code "\300\301!\210\302\303\304\305\306\307\310\311\312&\210\313\314\315\316\317\320\321\322&\210\323\324\325\326\327\330\321\314&\210\323\331\332\333\327\334\321\314&\210\323\335\336\337\327\340\321\314&\210\323\341\315\342\327\343\321\314&\207" [require ox-html org-export-define-derived-backend freemind html :menu-entry (102 "Export to Freemind Mindmap" ((102 "As Freemind Mindmap file" org-freemind-export-to-freemind) (111 "As Freemind Mindmap file and open" (lambda (a s v b) (if a (org-freemind-export-to-freemind t s v b) (org-open-file (org-freemind-export-to-freemind nil s v b))))))) :translate-alist ((headline . org-freemind-headline) (template . org-freemind-template) (inner-template . org-freemind-inner-template) (section . org-freemind-section) (entity . org-freemind-entity)) :filters-alist ((:filter-options . org-freemind-options-function) (:filter-final-output . org-freemind-final-function)) custom-declare-group org-export-freemind nil "Options for exporting Org mode files to Freemind Mindmap." :tag "Org Export Freemind Mindmap" :group org-export custom-declare-variable org-freemind-styles '((default . "\n") (0 . "\n\n") (1 . "\n\n\n") (2 . "\n\n\n") (3 . "\n\n") (4 . "\n")) "List of Freemind node styles.\nEach entry is of the form (STYLE-NAME . STYLE-SPEC). STYLE-NAME\ncan be one of an integer (signifying an outline level), a string\nor the symbol `default'. STYLE-SPEC, a string, is a Freemind\nnode style." :type (alist :options (default 0 1 2 3) :key-type (choice :tag "Style tag" (integer :tag "Outline level") (const :tag "Default value" default) (string :tag "Node style")) :value-type (string :tag "Style spec")) org-freemind-style-map-function 'org-freemind-style-map--automatic "Function to map an Org element to it's node style.\nThe mapping function takes two arguments an Org ELEMENT and INFO.\nELEMENT can be one of the following types - `org-data',\n`headline' or `section'. INFO is a plist holding contextual\ninformation during export. The function must return a STYLE-SPEC\nto be applied to ELEMENT.\n\nSee `org-freemind-style-map--automatic' for a sample style\nfunction. See `org-freemind-styles' for a list of named styles." (radio (function-item org-freemind-style-map--automatic) (function-item org-freemind-style-map--default) function) org-freemind-section-format 'note "Specify how outline sections are to be formatted.\nIf `inline', append it to the contents of it's heading node. If\n`note', attach it as a note to it's heading node. If `node',\nattach it as a separate node to it's heading node.\n\nUse `note', if the input Org file contains large sections. Use\n`node', if the Org file contains mid-sized sections that need to\nstand apart. Otherwise, use `inline'." (choice (const :tag "Append to outline title" inline) (const :tag "Attach as a note" note) (const :tag "Create a separate node" node)) org-freemind-pretty-output "Enable this to generate pretty Freemind Mindmap." boolean] 9) #@456 Convert PARSED-XML in to XML string. PARSED-XML is a parse tree as returned by `libxml-parse-xml-region'. CONTENTS is an optional string. Ignore CONTENTS, if PARSED-XML is not a sole XML element. Otherwise, append CONTENTS to the contents of top-level element in PARSED-XML. This is an inverse function of `libxml-parse-xml-region'. For purposes of Freemind export, PARSED-XML is a node style specification - "..." - as a parse tree. (defalias 'org-freemind--serialize #[(parsed-xml &optional contents) "\204\303\207;\203 \207@9\203W\304\305A@\306#AA\204%\n\203C\307\310@ \303\230\2033\303\2026\306 P\311AA!\nP@%\202U\307\312@ \303\230\203Q\303\202T\306 P#)\207\304\311\303#\207" [parsed-xml attributes contents "" mapconcat #[(av) "\301\302@A#\207" [av format "%s=\"%s\""] 4] " " format "\n<%s%s>%s\n" org-freemind--serialize "\n<%s%s/>"] 6 (#$ . 3481)]) #@181 Return parse tree for XML-STRING using `libxml-parse-xml-region'. For purposes of Freemind export, XML-STRING is a node style specification - "..." - as a string. (defalias 'org-freemind--parse-xml #[(xml-string) "\302\303\304\"rq\210\305\216 \206\306c\210\307ed\"+\207" [#1=#:temp-buffer xml-string generate-new-buffer " *temp*" t #[nil "\301!\205 \302!\207" [#1# buffer-name kill-buffer] 2] "" libxml-parse-xml-region] 3 (#$ . 4395)]) #@229 Return a node style corresponding to relative outline level of ELEMENT. ELEMENT can be any of the following types - `org-data', `headline' or `section'. See `org-freemind-styles' for style mappings of different outline levels. (defalias 'org-freemind-style-map--automatic #[(element info) "\211:\204\211;\205\306\262\202\211@9\205\211@\262\211\307\267\202>\310\n\"\202?\311!\211\2045\312\202:\310 \n\"T)\202?\313)\314\f \"\206P\314\315 \"\206P\316)\207" [element #1=#:temp info parent style-name org-freemind-styles plain-text #s(hash-table size 2 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (headline 34 section 41)) org-export-get-relative-level org-export-get-parent-headline 1 0 assoc-default default ""] 4 (#$ . 4863)]) #@188 Return the default style for all ELEMENTs. ELEMENT can be any of the following types - `org-data', `headline' or `section'. See `org-freemind-styles' for current value of default style. (defalias 'org-freemind-style-map--default #[(element info) "\301\302\"\206\303\207" [org-freemind-styles assoc-default default ""] 3 (#$ . 5652)]) #@173 Return Freemind node style applicable for HEADLINE. ELEMENT is an Org element of type `org-data', `headline' or `section'. INFO is a plist holding contextual information. (defalias 'org-freemind--get-node-style #[(element info) "\306!\204\307 \n\"\310 !\211A@\311 \312 \211A \242\211\2031\313 \"\202)\f\203;\fA \240\210\314\f!,\207" [org-freemind-style-map-function element info style data attributes fboundp org-freemind-style-map--default org-freemind--parse-xml (POSITION FOLDED TEXT CREATED ID MODIFIED) nil assq-delete-all org-freemind--serialize ignored-attrs attr] 4 (#$ . 6010)]) #@1570 Build a Freemind node with style STYLE-1 + STYLE-2 and add CONTENTS to it. STYLE-1 and STYLE-2 are Freemind node styles as a string. STYLE-1 is the base node style and STYLE-2 is the overriding style that takes precedence over STYLE-1. CONTENTS is a string. Return value is a Freemind node with following properties: 1. The attributes of " " element is the union of corresponding attributes of STYLE-1 and STYLE-2. When STYLE-1 and STYLE-2 specify values for the same attribute name, choose the attribute value from STYLE-2. 2. The children of " " element is the union of top-level children of STYLE-1 and STYLE-2 with CONTENTS appended to it. When STYLE-1 and STYLE-2 share a child element of same type, the value chosen is that from STYLE-2. For example, merging with following parameters STYLE-1 => STYLE-2 => CONTENTS => will result in following node: RETURN => . (defalias 'org-freemind--build-stylized-node #[(style-1 style-2 &optional contents) "\306\206\307!\306\n\206\307! A@ A@\211 AA\f AA\211 \310\f\211A\242\211\203I@ \236\204+ B \202+)\310\f\211A\f\242\211\203s;\204i@\236\204MB\202M)\311 D\244\312\". \207" [style-1 data1 style-2 data2 attr1 attr2 org-freemind--parse-xml "" nil node org-freemind--serialize merged-attr children1 children2 merged-children attr child merged-data contents] 4 (#$ . 6629)]) (defalias 'org-freemind--richcontent #[(type contents &optional css-style) "\303\267\202\304\202\305\202\305 \306\307\203\310\202\311\312\307\313\312##\266\202\211\306\307\2032\310\2023\311\312\307\313\312##\266\202\312\230\203F\312\202V\314\315\314\316\n\206P\312\314\317 \"##*\207" [type contents css-style #s(hash-table size 2 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (note 6 node 10)) "NOTE" "NODE" nil replace-regexp-in-string "\\`\\([ ]*\n\\)+" "\\`[ \n ]+" "" "[ \n ]+\\'" format "\n%s\n" "\n\n%s\n\n%s\n" "\n%s\n"] 10]) (defalias 'org-freemind--build-node-contents #[(element contents info) "\211:\204\211;\205\306\262\202\211@9\205\211@\262\211\307\267\202E\310\211;\2033\311\312#\266\202\202H\313A@\"\266\202\202H\313\n\310\"\202H\314\315!)\211:\204V\316\262\202a\211@9\203a\211AA\262\305\f\236\317\320\316\321\313\n\322\"!'>\204\323\324\320\313\n\322\"D\"\210\313\n\322\"\325H\326\316\211\211\211&(\327 (\n#))\330\f\331\332\n\333%\211*\205\251\334*\n\")+)+\205\265,P-\335 \n\".\336\267\202\374\337\340\341\342 \"-P\"\202\375\337\340\341\343 \"\"\337\344-\"P\202\375\337\340\341\343 \"\" \205\370\345\346 \n\"\316\337\340-\"#P\202\375\316)+?\205,P.\207" [element #1=#:temp info title element-contents section plain-text #s(hash-table size 2 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (headline 34 org-data 62)) :title get-text-property 0 plist-get error "Shouldn't come here" nil record org-export-backend type-of :back-end signal wrong-type-argument 1 ((section lambda (e c i) c)) org-export-data-with-backend org-element-map headline identity t org-export-low-level-p org-export-data #s(hash-table size 3 test eq rehash-size 1.5 rehash-threshold 0.8125 purecopy t data (inline 196 note 209 node 225)) org-freemind--richcontent node format "\n

%s

" "\n

%s\n

" note org-freemind--build-stylized-node org-freemind--get-node-style cl-struct-org-export-backend-tags backend section-contents first-child-headline itemized-contents-p contents node-contents org-freemind-section-format] 10]) #@192 Return complete document string after Freemind Mindmap conversion. CONTENTS is the transcoded contents string. RAW-DATA is the original parsed data. INFO is a plist holding export options. (defalias 'org-freemind-template #[(contents info) "\303\304\305\306\307\"\307\310\311\"\312 \n#)#\"\207" [info org-data contents format "\n%s\n" org-freemind--build-stylized-node org-freemind--get-node-style nil plist-get :parse-tree org-freemind--build-node-contents] 9 (#$ . 10937)]) #@152 Return body of document string after Freemind Mindmap conversion. CONTENTS is the transcoded contents string. INFO is a plist holding export options. (defalias 'org-freemind-inner-template #[(contents info) "\207" [contents] 1 (#$ . 11455)]) (defalias 'org-freemind--tags #[(tags) "\301\302\303#\207" [tags mapconcat #[(tag) "\301\302\303#\207" [tag format "\n" ""] 4] "\n"] 4]) #@143 Transcode an ENTITY object from Org to Freemind Mindmap. CONTENTS are the definition itself. INFO is a plist holding contextual information. (defalias 'org-freemind-entity #[(entity contents info) "\301\211;\203 \302\303#\207\304A@\"\207" [entity :utf-8 get-text-property 0 plist-get] 6 (#$ . 11882)]) #@154 Transcode a HEADLINE element from Org to Freemind Mindmap. CONTENTS holds the contents of the headline. INFO is a plist holding contextual information. (defalias 'org-freemind-headline #[(headline contents info) "\206\306\307 \n\"\310 \n\"\311\312 \211;\203\"\313\314#\266\202\202*\315A@\"\266\202\n\"\315\n\316\"\205Y\317 \211;\203E\313\314#\266\202\202M\315A@\"\266\202\211.\205X\311.\n\")\211.\205x\320 \211;\203p\313\314#\266\202\202x\315A@\"\266\202/\315\n\321\"\205\205\322 \n\"0\315\n\323\"\205\247\324 \211;\203\237\313\314#\266\202\202\247\315A@\"\266\2021\325 \n\"?\205\300\307 \n\"\205\300\326\327\330 \n\"\331#2\311\312 \211;\203\324\313\314#\266\202\202\334\315A@\"\266\202\n\"3\330 \n\"@4\332 \211;\203\370\313\314#\266\202\202\315A@\"\266\202\203\333\202\230\325 \n\"\203\334 \n#\202\230\326\327\330 \n\"\335#2\336\333\337 \211;\2033\313\314#\266\202\202;\315A@\"\266\202\3402P\341 \211;\203P\313\314#\266\202\202X\315A@\"\266\202E\"\2115@65A74\342\246\314U8\343\344 \n\"\345\34668\203\347\202\200\350\f\351U\203\212\352\202\213\353$\354 \n#\3550!P#-.\n\207" [contents headline info numberedp level text "" org-export-numbered-headline-p org-export-get-relative-level org-export-data :title get-text-property 0 plist-get :with-todo-keywords :todo-keyword :todo-type :with-tags org-export-get-tags :with-priority :priority org-export-low-level-p mapconcat number-to-string org-export-get-headline-number "." :footnote-section-p nil org-html-headline "-" remove :CUSTOM_ID "sec-" :ID 2 org-freemind--build-stylized-node org-freemind--get-node-style format "\n" "left" "right" 1 "true" "false" org-freemind--build-node-contents org-freemind--tags todo todo-type tags priority section-number full-text headline-order ids preferred-id extra-ids left-p] 11 (#$ . 12198)]) #@152 Transcode a SECTION element from Org to Freemind Mindmap. CONTENTS holds the contents of the section. INFO is a plist holding contextual information. (defalias 'org-freemind-section #[(section contents info) "\304!\211\205\305 \n\"\205 )\207" [section parent info contents org-export-get-parent-headline org-export-low-level-p] 4 (#$ . 14136)]) #@54 Return CONTENTS as pretty XML using `indent-region'. (defalias 'org-freemind-final-function #[(contents backend info) "\204 \207\303\304\305\"r\nq\210\306\216\307 \210 c\210\310ed\"\210\311ed\"+\207" [org-freemind-pretty-output contents #1=#:temp-buffer generate-new-buffer " *temp*" t #[nil "\301!\205 \302!\207" [#1# buffer-name kill-buffer] 2] nxml-mode indent-region buffer-substring-no-properties] 3 (#$ . 14494)]) #@148 Install script in export options when appropriate. EXP-PLIST is a plist containing export options. BACKEND is the export back-end currently used. (defalias 'org-freemind-options-function #[(info backend) "\301\302\303#\207" [info plist-put :with-smart-quotes nil] 4 (#$ . 14928)]) #@838 Export current buffer to a Freemind Mindmap file. If narrowing is active in the current buffer, only export its narrowed part. If a region is active, export that region. A non-nil optional argument ASYNC means the process should happen asynchronously. The resulting file should be accessible through the `org-export-stack' interface. When optional argument SUBTREEP is non-nil, export the sub-tree at point, extracting information from the headline properties first. When optional argument VISIBLE-ONLY is non-nil, don't export contents of hidden elements. When optional argument BODY-ONLY is non-nil, only write code between "" and "" tags. EXT-PLIST, when provided, is a property list with external parameters overriding Org default settings, but still inferior to file-local settings. Return output file's name. (defalias 'org-freemind-export-to-freemind #[(&optional async subtreep visible-only body-only ext-plist) "\306\307 \"\310\311\312\n\f  \f&+\207" [extension subtreep file org-export-coding-system async visible-only ".mm" org-export-output-file-name utf-8 org-export-to-file freemind body-only ext-plist] 8 (#$ . 15218) nil]) (provide 'ox-freemind)