Add a font

Re: Add a font

by Janne Mikkonen -
Number of replies: 11
This is extension to http://moodle.org/mod/forum/discuss.php?d=6167#28656

Okey, here is how it can be made:

  1. Create buttons sizes 18x18 px, color depth 2 bit (black and white), set white transparent.
  2. Save images to folder /lib/editor/images
  3. Add buttons to toolbar: (find section this.toolbar in htmlarea.php, row 148) and add new row to the toolbar:
  4. create a function that actually inserts selected character:
    Paste this function right under HTMLArea._insertChar function (row 1615).
  5. Next we need to add some actions to those buttons, so find section this.btnList (row 217) and add lines:
    _insertSpecial takes one argument and it's the character which is going to be inserted. Every button needs its own function call.
  6. Now it's ready to rock! Empty your browser cache and try it on.
WORD OF CAUTION:
  1. Make a backup of your original htmlarea.php -file.
  2. Every client needs igbo.ttf font or outcome might be somewhat interesting.

Average of ratings: Useful (1)
In reply to Janne Mikkonen

Re: Add a font

by Anja Choon -
Hello Janne, I can't really answer to that one right now. First I have to spend about an eternity reading it. winken Nevertheless, I wanted to thank you already, and I will inform you about the outcome (just don't expect it soon!). Thanks a lot, Anya
In reply to Anja Choon

I finally got it!!!

by Anja Choon -

... and the whole time there has been just one comma too much! Breites Grinsen Thanks again, Anya

In reply to Anja Choon

Re: Add a font

by Anja Choon -

Hi Janne, our instructor Ejike Eze just has seen this new keyboard. He is very excited about it though three letters are still not working. I should forward his gratitude to you.

About the three characters that are still missing:

Can it be that some characters can not be inserted? I think the following didn't work because of the characters that were to be inserted:

  insertchartwentyeight: [ "Insert char", "28.gif", false, function(e) {e._insertSpecial(''');} ],

  insertcharthirtynine: [ "Insert char", "39.gif", false, function(e) {e._insertSpecial('\');} ],

  insertcharfortyone: [ "Insert char", "41.gif", false, function(e) {e._insertSpecial('@');} ]

When I replace ', \ and @ with numbers it works (besides that the buttons now insert numbers of course).

I meele (thanks in Igbo), Anya

In reply to Anja Choon

Re: Add a font

by W Page -
Hi Chief and Anja!

I looked at the font  that I downloaded but I did not see any letters with dots under them.  Could it be I do not know how to use the font correctly so I can get these letters to type out?

Need your help with this.

WP1

In reply to W Page

Re: Add a font

by Anja Choon -

Hi WP1! In order to get the subdoted vowels you have to type in the umlauted ones (but only ä/ ï , ö and ü) but I assume that your keyboard does not have umlauts. You can copy and paste the umlauts I gave you. How to type the rest of it is shown in the following posting: http://moodle.org/mod/forum/discuss.php?d=6167#28656. You have to compare the two first tables and see which character has to be used in order to produce which Igbo character. I hope this helps. It's nice hearing that you still are interested in it. lächelnd See ya! Anya

In reply to Anja Choon

Re: Add a font

by W Page -
Hi Anja,

I am finding this a bit confusing but I will continue to try.  Is it  "OK" to email you directly if I continue to have problems with this?

WP1

In reply to Anja Choon

Re: Add a font

by Janne Mikkonen -
' and \ are special characters, so they'll need to be escaped like ' and \ .

@ character is a different story it self, when you paste this char into editor it assumes we are making a mailto: -hyperlink, so I do not know how to pass this problem.

ps. You could try replace @ sign with iso entity @
In reply to Janne Mikkonen

Re: Add a font

by Anja Choon -

After using iso entities that you gave me it is working completely but I had to replace not only the @. When I had done this, there were still three missing letters (I didn't notice yesterday that & hadn't work either). Therefore I replaced them as well and then it worked. <quote whom="myself">Thanks</quote> winken, Anya

PS: In case you want to have a look at it, I created a user for you using your usual username and password for testing purposes. I will delete it again after the week-end. http://uwandiigbo.com/moodle2/moodle/

In reply to Janne Mikkonen

Re: Add a font

by Jordi Prats -
I've followed the instructions but it does not intsert any char. Maybe it have changed since March 2004?

Nowadays what should do to do the same? I'm using the latest version (1.5.3)

Thank you all

(I've attached my modified version)