Customize firepad toolbar

308 views
Skip to first unread message

jérôme SALVAT

unread,
Feb 1, 2016, 5:28:00 AM2/1/16
to Firepad
Hi everyone,

I'm new with firepad.

I would like to know how to customize firepad toolbar (codemirror integration).

I wanted to customize rich-text-toolbar.js from git but as our project references only the whole CDN file firepad.min.js ...

I don't jnow how can i handle that.

My main goal is to change buttons text and icons.


Thanks for your answers

Sincerely yours.

Michael Lehenbauer

unread,
Feb 1, 2016, 11:23:52 AM2/1/16
to jérôme SALVAT, Firepad
Unfortunately I think your options are probably along the lines of either modifying the code in git or else pass richTextToolbar: false when instantiating firepad and then just create your own toolbar that calls methods on the firepad instance.

Hope this helps,
-Michael

--
You received this message because you are subscribed to the Google Groups "Firepad" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firepad-io+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/firepad-io/a110b3c5-3981-4450-bebf-400be2614e00%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Mika Genic

unread,
Feb 1, 2016, 5:06:20 PM2/1/16
to Firepad, jsalvat...@gmail.com
Yes customizing the firepad bar is difficult which is unfortunate. I don't like how the bar is so tightly coupled to the rest of firepad code. Adding buttons is especially tricky. 

Look for the firepad.RichTextToolbar = (function(global) { function.

I hope this part can be reworked one day.

Guy Goldstein

unread,
Feb 7, 2016, 4:00:43 AM2/7/16
to Mika Genic, Firepad, jsalvat...@gmail.com
I bet you can do most/all of what you want with CSS styling the toolbar!


--
Guy Goldstein
ReadThrough.com - We give your script a voice™
WriterDuet.com - Write together, write away™

Mika Genic

unread,
Feb 7, 2016, 4:06:19 AM2/7/16
to Firepad, mika...@gmail.com, jsalvat...@gmail.com
not really, for example I needed an icon pushed to the right and had to change the code. If you want to add a button you really need to dig in ...

Guy Goldstein

unread,
Feb 7, 2016, 4:07:52 AM2/7/16
to Mika Genic, Firepad, jsalvat...@gmail.com
I was responding to just the original question, which said: "My main goal is to change buttons text and icons."

Should be able to do that through CSS fairly easily, if I'm not mistaken.


--
Guy Goldstein
ReadThrough.com - We give your script a voice™
WriterDuet.com - Write together, write away™

jérôme SALVAT

unread,
Feb 12, 2016, 4:35:46 AM2/12/16
to Firepad
Thks for all your answers, we decided for the moment not to customize it, we will try when we will have more time

Thanks again to all. have a nice day !
Reply all
Reply to author
Forward
0 new messages