12

I asked the same question when I used Maverick Meerkat but I can't make that solutions work on Unity. I want to use the keys ´ followed by c and the output should be "ç". It works that way in Windows out of the box, and it did work in Ubuntu 10.10 following the solutions given in the question above. But in 11.04 it outputs "ć". How to change that?

2
  • We're searching for a solution here but we should really be asking ourselves why this behaviour in the first place. Windows and Mac behave as expected for us intl layout: ' + c = ç. Why going through all this suffering and misery for so many years on linux systems? Apr 9, 2020 at 18:12
  • like this: ç ... jkjk
    – TardisGuy
    Apr 15, 2020 at 4:36

11 Answers 11

9

Edit /usr/lib/gtk-2.0/2.10.0/gtk.immodules Modify the line where you can find "cedilla" add ":en" at the end

"cedilla" "Cedilla" "gtk20" "/usr/share/locale" "az:ca:co:fr:gv:oc:pt:sq:tr:wa:en"

Edit /etc/environment Add: export GTK_IM_MODULE=cedilla


Edit for Ubuntu 12.10: (according to the other answer by Hoerlle)

the gtk.immodule file is located at:

/usr/lib/x86_64-linux-gnu/gtk-2.0/2.10.0/gtk.immodules

or

/usr/lib/i386-linux-gnu/gtk-2.0/2.10.0/gtk.immodules


For KDE and other applications that are not GTK: Edit: /usr/share/X11/locale/en_US.UTF-8/Compose

Find all ocorrencies for ć and replace it all for ç, remember to look for the the uppercase matches too Ć and Ç

You may need to restart your gnome.

7

In Ubuntu 13.10, I fixed it by adding the following lines in /etc/environment:

GTK_IM_MODULE=cedilla 
QT_IM_MODULE=cedilla 
3
  • For me, in Ubuntu 13.10 and Gnome Shell, worked too.
    – euDennis
    Jan 21, 2014 at 10:04
  • It worked too in Mint 18
    – Luciano
    Mar 13, 2018 at 19:48
  • It didn´t work on NixOS.
    – Felipe
    Mar 9 at 20:22
3

Try using the Dvorak International layout with dead keys;there's a good possibility that QWERT International with dead keys also uses these keys. On mine, the comma is a live key. (It's used often enough that it would be annoying if it were a dead key.)

For a ç. try AltGr (right Alt) + ,. For a capital, Ç, try Shift+AltGr+,.

1
  • 2
    using Dvorak might be more annoying than a dead comma key for people that are used with QWERT
    – user47206
    Apr 17, 2013 at 9:33
2

Using the same answer for the same question found here: How do I make Cedilla (ç) character available in English USA?

If you're in a hurry, do this and you'll get "ç" instead of "ć":

Press "AltGr + ," then "c".

If you want to know a bit more, keep on reading.

This may be solved already by using one of the answers above, but I realized the best thing to do is to use the keyboard layout, instead of changing things you'll have to eventually change again in the future (after updates, for example).

Before I start, keep in mind I'm using Ubuntu 14.04.2, which is not the same distro as the original question mentions (11.04). Anyway, I believe most users have already migrated to newer versions by now. So:

$ cat /etc/issue
Ubuntu 14.04.2 LTS \n \l

Okay, the first thing I did was looking at the immodules files:

/usr/lib/x86_64-linux-gnu/gtk-2.0/2.10.0/immodules.cache /usr/lib/x86_64-linux-gnu/gtk-3.0/3.0.0/immodules.cache

At the header, those files clearly mention they should not be changed, since they're generated automatically:

# GTK+ Input Method Modules file
# Automatically generated file, do not edit
# Created by /usr/lib/x86_64-linux-gnu/libgtk-3-0/gtk-query-immodules-3.0 from gtk+-3.10.8

So changing them, although it may solve the problem temporarily, is not ideal.

Looking around, I found the best answer ever about why we get a "ć" instead of a "ç" when typing ' + c: because we're really putting an acute accent on the top of letter "c". So the layout is right. With that in mind, how would one put a "kind of a" comma at the bottom of the letter "c"? Using a comma, of course!

So, the solution was the key combination AltGR + , and then "c".

No need for changing any configuration on your computer.

1
  • NixOS here, it shows this to me: © 🤡
    – Felipe
    Mar 9 at 20:23
1

Use the accent, not the apostrophe:

accent + c (´+c) = ç trencada

1
  • I was using the accent <kbd>´</kbd> all the time, but the question didn't reflect it, so I edited the question, invalidating your answer. Sorry
    – Jader Dias
    Sep 2, 2011 at 14:08
1

In Ubuntu 12.10 the gtk.immodules file to be edited are located at:

/usr/lib/x86_64-linux-gnu/gtk-2.0/2.10.0/gtk.immodules

or

/usr/lib/i386-linux-gnu/gtk-2.0/2.10.0/gtk.immodules
0

In Xfce 12.10 I have solved it by installing ibus package and its dependencies.

This is a bug reported here (and the solution is mentioned in a comment - more specifically here.)

0

In Kubuntu 15.04, after replacing cedillas for the /usr/share/X11/locale/en_US.UTF-8/Compose as described by others above, only qt-based apps were OK. After that, I installed ibus-gtk and ibus-gtk3 and it fixed my problem to firefox and other gtk-based apps as well.

0

First find the key that is used to type accents just like this é, è, á, à. (Normally it's in the same line as the numbers)

Press Alt+Gr and that key at the same time. When finished this, press C (or Shift+C, if you want a capital cedilla: Ç like this).

0

Same answer on SuperUser. Repeated below for convenience.


I have created a simple bash script following @ThoriumBR answer. This way, whenever there's an update to your system and you'll lose that config, you can just run the script again.

The script is idempotent, so feel free to run as many time as you want, the result won't change.

#!/usr/bin/env bash

# Setting vars up
COMPOSE_FILE='/usr/share/X11/locale/en_US.UTF-8/Compose'
GTK2_FILE='/usr/lib/x86_64-linux-gnu/gtk-2.0/2.10.0/immodules.cache'
GTK3_FILE='/usr/lib/x86_64-linux-gnu/gtk-3.0/3.0.0/immodules.cache'
ENV_FILE='/etc/environment'

# Backing up files
sudo cp ${COMPOSE_FILE} ${COMPOSE_FILE}.bak
sudo cp ${GTK2_FILE} ${GTK2_FILE}.bak
sudo cp ${GTK3_FILE} ${GTK3_FILE}.bak

# Fixing cedilla in Compose
sudo sed --in-place -e 's/ć/ç/g' ${COMPOSE_FILE}
sudo sed --in-place -e 's/Ć/Ç/g' ${COMPOSE_FILE}

# Fixing cedilla in GTK files
GTK_FILE_SEARCH_FOR='^"cedilla".*:en'
GTK_FILE_SED_EXP='s/^\(\"cedilla\".*:wa\)/\1:en/g'

grep -q ${GTK_FILE_SEARCH_FOR} ${GTK2_FILE}
[ $? -eq 1 ] && sudo sed --in-place -e ${GTK_FILE_SED_EXP} ${GTK2_FILE}
grep -q ${GTK_FILE_SEARCH_FOR} ${GTK3_FILE}
[ $? -eq 1 ] && sudo sed --in-place -e ${GTK_FILE_SED_EXP} ${GTK3_FILE}

# Fixing cedilla in environment file
ENV_FILE_GTK_LINE='GTK_IM_MODULE=cedilla'
ENV_FILE_QT_LINE='QT_IM_MODULE=cedilla'

grep -q ${ENV_FILE_GTK_LINE} ${ENV_FILE}
[ $? -eq 1 ] && echo ${ENV_FILE_GTK_LINE} | sudo tee -a ${ENV_FILE} > /dev/null
grep -q ${ENV_FILE_QT_LINE} ${ENV_FILE}
[ $? -eq 1 ] && echo ${ENV_FILE_QT_LINE} | sudo tee -a ${ENV_FILE} > /dev/null

Then you can save it to a file such as fix-cedilla.sh and run it with bash fix-cedilla.sh. Or you can mark that file as executable with chmod +x fix-cedilla.sh and run it with ./fix-cedilla.sh.

You can/should also add it to your dotfiles repo (example of mine) so next time you (re)install your OS it's handy in a known place ;-)

-1

EDIT: If all you want is to change the ç and not the others consonant accented keys that comes with US-international layout from Linux:

  1. Create a file named .XCompose
  2. Put in the beginning of the file include "%L" this will import the original configuration of /usr/share/X11/locale/en_US.UTF-8/Compose
  3. Then add those lines :

< dead_acute>< C> : "Ç"

< dead_acute>< c> : "ç" without the spaces inside the < >

  1. Save your file in ~/ directory

  2. Reboot

===========================================================================

But if you want your keyboard act like US-international from Windows :

For everyone that wanted that US-international keyboard like Windows. There is a github repo that can make this work: https://github.com/raelgc/win_us_intl Here what you want to do:

  1. download the zip file

  2. extract wherever you want, your focus should be on the XCompose file.

  3. Open the XCompose file with your preferred text editor, and then put bellow include "/usr/share/X11/locale/en_US.UTF-8/Compose" a line like this: include "%L"

  4. Move the XCompose file to the ~/ directory

  5. Reboot

9
  • 2
    Some of those steps have bad side effects, and don't really contribute to the solution. So I downvoted; sorry. Apr 14, 2020 at 18:58
  • @GunnarHjalmarsson could you please tell me what are those bad side effects ? Also the user wanted his US-international keyboard behave just like Windows out of the box, and with these steps you can achieve it. export GTK_IM_MODULE="xim" is for the .XCompose file to be readed, and IBus take precedence over some applications keyboard shortcuts, so you would have to redefine key combinations on both side to avoid such effects Apr 15, 2020 at 4:05
  • @GunnarHjalmarsson Anyway I edited the post, could you check now if it's a good solution ? Because it works wonderful for me, like before I did this steps if i hit " 'm" for exemple it would show me an accented m, and it was like this for every consonant letter. Apr 15, 2020 at 4:24
  • Gtk reads ~/.XCompose - you don't need to enable XIM for that. XIM is an old method with issues, and especially the en_US.UTF-8 Compose file is huge and might affect performance adversely. As regards IBus it may have some effect on shortcuts, but please note that IBus is installed by default in standard Ubuntu. And if you tell im-config to not start it, GNOME will start it and configure the important variables anyway. Apr 16, 2020 at 17:41
  • @GunnarHjalmarsson Ohh I see, well sorry I didn't know about this, I was just doing some steps that I found searching on the internet. I edited the post. Apr 17, 2020 at 22:04

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .