Filters: Auto non-breaking space filter

filter_vowels
Maintained by Kamil ŁuczakKamil Łuczak
Auto change spaces after chosen vowels and words into non-breaking space -   You can specify vowels (letters) and words after wchich space will be changed into non-breaking space.
1 sites
4 fans

This filter automaticly changes space after chosen vowels and words into non-breaking space -  

You can specify vowels (letters) and words after wchich space will be changed into non-breaking space in filter settings.


For example paragraph like this:

The quick brown fox jumps over a 

lazy dog.


Will be displayed as:

The quick brown fox jumps over

a lazy dog.


Betwen a and lazy will be inserted    =   a lazy 


Installation

Install the plugin like any other plugin to folder /filter/vowels

If You're installing with Plugin installer using zip archive choose plugin type: Text filter (filter)

See http://docs.moodle.org/28/en/Installing_plugins for details on installing Moodle plugins


Usage

First, activate the filter_vowels plugin in Site Administration -> Plugins -> Filters -> Manage filters


Settings

filter_vowels has a settings page to allow you to change the filter to only certain letters.

You can also enable function that changes spaces after selected words into hard spaces.

Screenshots

Screenshot #0
Screenshot #1

Contributors

Kamil Łuczak
Kamil Łuczak (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Picture of Plugins bot
    Sun, Jun 28, 2015, 2:06 PM
  • Picture of David Mudrák
    Fri, Jul 3, 2015, 1:43 PM

    Thanks Kamil for sharing this filter with the Moodle community. I was able to check the basic functionality and do a quick code review. It seems the current version would also process text inside the value of attributes - such as <img src="..." alt="Bolek i Lolek"> - and also, as you mention in a todo comment in the code, in javascript and other places. I am sure you will want to address this is a future update of the filter. Also, let me recommend to add unit tests your filter. You will find them really useful during further development.

    I am going to approve the plugin now. You are cleared to land, welcome to the Plugins directory!

  • Picture of Mike Carrington
    Wed, Jul 8, 2015, 10:24 PM
    Hi Kamil, I just wanted to ask if the filter allows you to add non-breaking spaces BEFORE certain words? I use a lot of numerical data with units (eg 1.34 kJ/mol) and it looks terrible when the units are on the next line. I tend to leave out the space, but that doesn't look right either.
  • Kamil Łuczak
    Thu, Jul 9, 2015, 3:52 PM
    Hi Mike, im working on next version with fixed some bugs mentioned by David. I will add feature You requested with non-breaking spaces before selected words.
    I will try to share the new version before end of weekend.
Please login to post comments