Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#13 2014-02-09 11:33:26

demoncleaner
Plugin Author
From: Germany
Registered: 2008-06-29
Posts: 220
Website

Re: [howto] A fullscreen editor for write your article body

Thanks for the quick answer. I am confused. The editor does not “color” anything in my case right now. Textile highlighting is exactly what I would want. What do you mean by “only highlight block tags”. What I would like to achive is … that in case I have inside of an article a macro… for example

<txp:mymacro name=“aname” id=“1”>
Content of the macro container
</txp:mymacro>

That first and third line are colored to make the user understand that he should better not touch the colored part.
Or more simple example… that if I have an inline image like <txp:image id=“1” /> in some text, that the user sees directly that there are some “<” that he better should not touch to not blow of the whole site.

Offline

#14 2014-02-10 19:09:50

sacripant
Plugin Author
From: Rhône — France
Registered: 2008-06-01
Posts: 479
Website

Re: [howto] A fullscreen editor for write your article body

Perhaps you confuse the textile syntax with textpattern syntax?

for Textile syntax see here

 h1. My Level 1 Title

 p(my class). My paragraph with *this text in strong emphasis*

In this editor, by default h1. and p(my class). are highlighting (blocks elements), but * for strong element is not highlight.

In your exemple, you write about Textpattern syntax. Textpattern syntax is based on xml syntax.
If you want activated xml syntaxe in Ace Editor, make modification I asked before.

Last edited by sacripant (2014-02-10 19:11:16)

Offline

#15 2014-02-10 19:12:20

demoncleaner
Plugin Author
From: Germany
Registered: 2008-06-29
Posts: 220
Website

Re: [howto] A fullscreen editor for write your article body

Ahhhh. My fault. Sounds like the solution of my problems. Just mixed textile/textpattern indeed. Thanks a lot. I will give it a try in a moment. =)

Offline

#16 2014-02-25 02:31:47

jstubbs
Moderator
From: Hong Kong
Registered: 2004-12-13
Posts: 2,395
Website

Re: [howto] A fullscreen editor for write your article body

Thanks to sacripant for posting his tutorial over on TXP Tips – Distraction free writing environment for Textpattern.

Offline

#17 2018-10-27 12:30:00

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,909
Website

Re: [howto] A fullscreen editor for write your article body

jstubbs wrote #279209:

Thanks to sacripant for posting his tutorial over on TXP Tips – Distraction free writing environment for Textpattern.

Re-discovering this again from that tips link. ;)

I still write my long-form outside of Txp first, and now that I’m going to include ePubs in my publishing offer, that will always be the case for long-form.

But I did notice in the to-dos of the tips write-up, Thomas, that you hoped to make a plugin out of this… Still the plan? I think it’s a good idea.

Offline

#18 2018-10-27 15:48:17

sacripant
Plugin Author
From: Rhône — France
Registered: 2008-06-01
Posts: 479
Website

Re: [howto] A fullscreen editor for write your article body

Hi Destry,

Since 2013, I wrote a big update last year :
tom_write_editor: a editor for geek writers
github.com/Sacripant/tom_write_editor/releases

It’s now a textpattern plugin.

I use it on my personal website. Still under Txp 4.6. I’m happy with him.
Not yet tested with Txp 4.7.
If you want to test and propose improvements, don’t hesitate.

Offline

#19 2023-03-02 09:17:16

demoncleaner
Plugin Author
From: Germany
Registered: 2008-06-29
Posts: 220
Website

Re: [howto] A fullscreen editor for write your article body

It seems to work fine in 4.8.8 as far as I can tell. I just re-discovered this nice plugin and could set it up with the advises sacripant gave me 9 (!) years ago. So cool that this is still helpful.

I am just wondering how I could achieve both:
Highlighting of textpattern AND textile syntax. Because IMHO it would be best that everything which should “not be touched carelessly” is highlighted. For me this would be shortcode/form tags but also textile tags. Any ideas?

Just as an info for others that might want to apply those changes:
They are not done in

ace-for-write-tab.js 

anymore. They must be done in

/tom-WE/assets/tom-WE.js

Just look for editor.ace.setTheme and editor.ace.getSession

Last edited by demoncleaner (2023-03-02 09:25:43)

Offline

Board footer

Powered by FluxBB