1 <html i18n:domain="plone">
3 <div metal:define-macro="wysiwygEditorBox">
5 <tal:block tal:define="wysiwyg python: here.portal_membership.getAuthenticatedMember().getProperty('wysiwyg_editor')=='Epoz';">
7 <tal:block tal:condition="wysiwyg"
8 tal:define="ztu modules/ZTUtils;
9 pss modules/Products/PythonScripts/standard;
10 text_format python: getattr(here,'text_format','html');
11 is_stx python:text_format=='structured-text';
12 is_ptx python:text_format=='plain';
13 url3 request/URL3|nothing;
14 pageurl python: test(here.portal_factory.isTemporary(here), url3, here.absolute_url());
15 getProperty python: here.stylesheet_properties.getProperty;
16 current_skin python: ztu.make_query(skin=request.get(here.portal_skins.getRequestVarname(), ''));"
18 tal:replace="structure python: here.Epoz(
20 data = (is_stx and pss.structured_text(inputvalue))
21 or (is_ptx and pss.newline_to_br(inputvalue))
23 toolbox = pageurl + '/epoz_toolbox',
24 lang = here.portal_properties.site_properties.default_language,
25 style = 'width: %s; height: %s; margin-top: 2px; border: %s;' % (path('width|string:99%'), path('height|string:450px'), getProperty('preBorder','1px solid #8cacbb'),),
26 button = 'background-color: %s; border: 1px solid %s; cursor: pointer; margin-right: 1px; margin-bottom: 1px;' % (
27 getProperty('contentTabBackground','#CDE2A7'),
28 getProperty('contentTabFontColor','#578308'),),
29 path = here.portal_url() + '/',
30 css = here.portal_url()+'/plone.css?'+pss.url_quote(current_skin),
31 customcss = here.portal_url()+'/ploneCustom.css?'+pss.url_quote(current_skin),
32 charset = here.portal_properties.site_properties.default_charset,
36 <tal:block condition="not: wysiwyg">
42 tal:content="inputvalue"
43 tal:attributes="name inputname;
45 tabindex tabindex|nothing;
47 cols cols|default;"></textarea>
52 <div metal:define-macro="textFormatSelector">
54 <tal:block tal:define="wysiwyg python: here.portal_membership.getAuthenticatedMember().getProperty('wysiwyg_editor')=='Epoz'">
56 <tal:block condition="wysiwyg">
62 <tal:block condition="not: wysiwyg">
65 tal:define="tabindex tabindex/next;
66 text_format python:request.get('text_format', getattr(here,'text_format','structured-text'))">
68 <label for="text_format" i18n:translate="label_format">Format</label>
70 <div class="formHelp" i18n:translate="help_format_wysiwyg">
71 If you are unsure of which format to use, just select Plain
72 Text and type the document as you usually do.
75 <input class="noborder"
78 value="structured-text"
80 id="cb_structuredtext"
81 tal:attributes="checked python:test(text_format=='structured-text', 1, None);
84 <label for="cb_structuredtext" i18n:translate="structured_text">Structured Text</label> <br />
86 <input class="noborder"
92 tal:attributes="checked python:test(text_format=='html', 1, None);
95 <label for="cb_html" i18n:translate="html">HTML</label> <br />
97 <input class="noborder"
103 tal:attributes="checked python:test(text_format=='plain', 1, None);
106 <label for="cb_plain" i18n:translate="plain_text">Plain Text</label>