.. You may want to use the usual include line. Uncomment and adjust the path. .. include:: ../Includes.txt ===================== EXT: EfA Font Resizer ===================== :Author: Kasper Skårhøj :Created: 2002-11-01T00:32:00 :Changed: 2011-11-08T16:04:21 :Classification: efafontsize :Keywords: forAdmins, forBeginners :Author: François Suter :Email: typo3@cobweb.ch :Info 4: :Language: en |img-1| |img-2| EXT: EfA Font Resizer - efafontsize .. _EXT-EfA-Font-Resizer: EXT: EfA Font Resizer ===================== Extension Key: efafontsize Language: en Keywords: forAdmins, forBeginners Copyright 2000-2011, François Suter, This document is published under the Open Content License available from http://www.opencontent.org/opl.shtml The content of this document is related to TYPO3 \- a GNU/GPL CMS/Framework available from www.typo3.org .. _Table-of-Contents: Table of Contents ----------------- `EXT: EfA Font Resizer 1 <#__RefHeading__638_65439829>`_ **`Introduction 3 <#__RefHeading__640_65439829>`_** `What does it do? 3 <#__RefHeading__642_65439829>`_ `Screenshots 3 <#__RefHeading__644_65439829>`_ `Credits 3 <#__RefHeading__646_65439829>`_ `Should you really use this extension? 3 <#__RefHeading__648_65439829>`_ `Questions? 3 <#__RefHeading__650_65439829>`_ `Keeping the developer happy 3 <#__RefHeading__652_65439829>`_ **`Users manual 4 <#__RefHeading__654_65439829>`_** `Installation 4 <#__RefHeading__656_65439829>`_ `Using the resizer 4 <#__RefHeading__658_65439829>`_ **`Configuration 5 <#__RefHeading__660_65439829>`_** `TypoScript Constants 5 <#__RefHeading__662_65439829>`_ `TypoScript Setup 5 <#__RefHeading__664_65439829>`_ **`To Do List 7 <#__RefHeading__666_65439829>`_** **`Known problems 8 <#__RefHeading__668_65439829>`_** .. _Introduction: Introduction ------------ .. _What-does-it-do: What does it do? ^^^^^^^^^^^^^^^^ This extension allows to display on your web site controls for changing the font size using JavaScript. Font size can be enlarged, reduced or reset to some default value. .. _Screenshots: Screenshots ^^^^^^^^^^^ Here's a web page with the three font size controls (larger, default and smaller). .. _img-3-Credits: |img-3| Credits ^^^^^^^^^^^^^^^ The JavaScript used in this extension was developed by the accessibility web site Einfach für Alle ( `http://www.einfach-fuer- alle.de/ `_ ). It was slightly modified to add the “reset” control. Permission to package this script into a TYPO3 extension was requested, but no answer was ever received. Since the script is free for download and devoid of any license or copyright notices, it is probably alright. I have added copyright notices in the JavaScript files, just so that the origin does not get forgotten. .. _Should-you-really-use-this-extension: Should you really use this extension? """"""""""""""""""""""""""""""""""""" This JavaScript has actually been removed from the Einfach für Alle web site by the authors themselves. There's a full explanation of the reasons, but it's only in German ( `http://www.einfach-fuer- alle.de/blog/id/2457/ `_ ). The gist of it is that the authors consider that such JavaScript is not really useful anymore. First of all it is useless for a whole bunch of people with disabilities (e.g. blind people don't care about the font size). These people generally have other means of reading or improving the readability of web sites. Furthermore most operating systems can now handle zooming natively, allowing to magnify the whole web page and not just the font of some areas. Also according to the Einfach für Alle team web site owners tend to put this kind of widget in their web site and think that they have solved all accessibility problems, whereas making a web site accessible requires much more than this. I'm not removing this extension from TER, because it is in use and some clients will still want to have such a widget in their web site, but you might want to try and argue that being serious about accessibility implies rather more efforts than just some font size changing JavaScript. .. _Questions: Questions? ^^^^^^^^^^ If you have any questions about this extension, please ask them in the TYPO3 English mailing list (typo3.english), so that others can benefit from the answers. .. _Keeping-the-developer-happy: Keeping the developer happy ^^^^^^^^^^^^^^^^^^^^^^^^^^^ If you like this extension, do not hesitate to rate it. Go the Extension Repository, search for this extension, click on its title to go to the details view, then click on the “Ratings” tab and vote (you need to be logged in). Every new vote keeps the developer ticking. So just do it! .. _Users-manual: Users manual ------------ .. _Installation: Installation ^^^^^^^^^^^^ The installation is quite simple: download and install the extension using the Extension Manager include the extension's static TS template into your template |img-4| .. _Using-the-resizer: Using the resizer ^^^^^^^^^^^^^^^^^ The font resizer cannot be used as a content element. It is designed to be used purely as a TypoScript inclusion in your template. This is done as follows (if using TemplaVoilà): :: lib.fontsize < plugin.tx_efafontsize_pi1 lib.fontsize { defaultFontSize = 80 fontSizeIncrement = 10 } and then using that lib.fontsize object in one of your elements. The syntax is similar with the markers system: :: temp.fontsize < plugin.tx_efafontsize_pi1 temp.fontsize { defaultFontSize = 80 fontSizeIncrement = 10 } page.subparts.FONTSIZE < temp.fontsize assuming you have a ###FONTSIZE### marker in your HTML model. On top of that an initialization script must be called as the very first thing after the tag. Let's assume that your PAGE object is called “page” and that the content first comes at index 10: :: page = PAGE page.10 = USER page.10 { ... } then the font resizer initialization must be called with an index smaller than 10, e.g.: :: page.1 < plugin.tx_efafontsize_pi1 page.1.userFunc = tx_efafontsize_pi1->initEfA Note that the **userFunc** must be changed. It is not the traditional “main” that is called in this case, but another method called “initEfA”. .. _Configuration: Configuration ------------- .. _TypoScript-Constants: TypoScript Constants ^^^^^^^^^^^^^^^^^^^^ .. ### BEGIN~OF~TABLE ### .. _defaultFontSize: defaultFontSize """"""""""""""" .. container:: table-row Property defaultFontSize Data type int Description Default font size expressed as a percentage (but without units) Default 100 .. _fontSizeIncrement: fontSizeIncrement """"""""""""""""" .. container:: table-row Property fontSizeIncrement Data type int Description Increment by which the size of the font should be varied (up or down) every time a control is pressed. Expressed as a percentage (but without units) Default 10 .. ###### END~OF~TABLE ###### .. _TypoScript-Setup: TypoScript Setup ^^^^^^^^^^^^^^^^ .. ### BEGIN~OF~TABLE ### .. _defaultFontSize: defaultFontSize """"""""""""""" .. container:: table-row Property defaultFontSize Data type int Description Default font size expressed as a percentage (but without units) Default {plugin.tx\_efafontsize\_pi1.defaultFontSize} .. _fontSizeIncrement: fontSizeIncrement """"""""""""""""" .. container:: table-row Property fontSizeIncrement Data type int Description Increment by which the size of the font should be varied (up or down) every time a control is pressed. Expressed as a percentage (but without units) Default {plugin.tx\_efafontsize\_pi1.fontSizeIncrement} .. _controlOrder: controlOrder """""""""""" .. container:: table-row Property controlOrder Data type string Description This string defines the order of display of the controls. It contains the three words “smaller”, “reset” and “bigger” separated by commas. It **must absolutely** contain those three words, even if you intend to hide some controls. Hiding a control is achieved by using the boolean value of each control as described below. If even one word is missing from this property, the script will revert to the default value. Default smaller,reset,bigger .. _bigger: bigger """""" .. container:: table-row Property bigger Data type boolean/ ->controlConfig Description Set to 1 to display the “Enlarge font size” control. Set to 0 to hide. Configuration parameters for the controls are entered as sub- properties. Default bigger = 1 bigger { insideHTML = IMAGE insideHTML.file = EXT:efafontsize/res/icons/bigger.gif } .. _reset: reset """"" .. container:: table-row Property reset Data type boolean/ ->controlConfig Description Set to 1 to display the “Reset font size” control. Set to 0 to hide. Configuration parameters for the controls are entered as sub- properties. Default reset = 1 reset { insideHTML = IMAGE insideHTML.file = EXT:efafontsize/res/icons/reset.gif } .. _smaller: smaller """"""" .. container:: table-row Property smaller Data type boolean/ ->controlConfig Description Set to 1 to display the “Reduce font size” control. Set to 0 to hide. Configuration parameters for the controls are entered as sub- properties. Default smaller = 1 smaller { insideHTML = IMAGE insideHTML.file = EXT:efafontsize/res/icons/smaller.gif } .. ###### END~OF~TABLE ###### [tsref:plugin.tx\_efafontsize\_pi1] **Control parameters** .. ### BEGIN~OF~TABLE ### .. _beforeHTML: beforeHTML """""""""" .. container:: table-row Property beforeHTML Data type cObj Description HTML to be displayed before the control proper Default .. _insideHTML: insideHTML """""""""" .. container:: table-row Property insideHTML Data type cObj Description The control itself Default an IMAGE cObj with a relevant icon (see above) .. _class: class """"" .. container:: table-row Property class Data type string Description Value of the class attribute to apply to the tag around the control Default .. _id: id "" .. container:: table-row Property id Data type string Description Value of the id attribute to apply to the tag around the control Default .. _name: name """" .. container:: table-row Property name Data type string Description Value of the name attribute to apply to the tag around the control Default .. _accesskey: accesskey """"""""" .. container:: table-row Property accesskey Data type string Description Access key for the control Default .. _onmouseover: onmouseover """"""""""" .. container:: table-row Property onmouseover Data type string/stdWrap Description JavaScript to execute upon the onmouseover event. It seems using double quotes inside this property doesn't work, so stick to single quotes. Default .. _onmouseout: onmouseout """""""""" .. container:: table-row Property onmouseout Data type string/stdWrap Description JavaScript to execute upon the onmouseout event. It seems using double quotes inside this property doesn't work, so stick to single quotes. Default .. _onfocus: onfocus """"""" .. container:: table-row Property onfocus Data type string/stdWrap Description JavaScript to execute upon the onfocus event. It seems using double quotes inside this property doesn't work, so stick to single quotes. Default .. _afterHTML: afterHTML """"""""" .. container:: table-row Property afterHTML Data type cObj Description HTML to be displayed after the control proper Default .. ###### END~OF~TABLE ###### [tsref:plugin.tx\_efafontsize\_pi1.controlConfig] .. _To-Do-List: To Do List ---------- Nothing planned. It is planned to make this extension obsolete soon. .. _Known-problems: Known problems -------------- None to date. Please report any problem to the project's bug tracker: http://forge.typo3.org/projects/extension-efafontsize/issues. 8 .. ######CUTTER_MARK_IMAGES###### .. |img-1| image:: img-1.png .. :align: left .. |img-2| image:: img-2.png .. :border: 0 .. :height: 21 .. :hspace: 9 .. :id: Grafik2 .. :name: Grafik2 .. :width: 87 .. |img-3| image:: img-3.png .. :align: left .. :border: 0 .. :height: 167 .. :id: graphics4 .. :name: graphics4 .. :vspace: 5 .. :width: 669 .. |img-4| image:: img-4.png .. :align: left .. :border: 0 .. :height: 176 .. :id: graphics1 .. :name: graphics1 .. :width: 551