Manjaro Difference between revisions of "Mozilla Firefox"

Difference between revisions of "Mozilla Firefox"

From Manjaro
imported>Excalibur1234
(fix and improve translation tags.)
 
(17 intermediate revisions by 5 users not shown)
Line 1: Line 1:
Installing Firefox the following way has one advantage: Firefox will update itself automatically as soon as an update is available.
<languages/>
This is great for users, who want to get the latest update as soon as possible without waiting for the next Manjaro update. It is also great for systems which need an updated (i.e. secure) web browser but are updated rarely.
__TOC__


<translate>
=Installing Firefox= <!--T:1-->


1. Find out, whether your Manjaro installation is 32bit or 64bit:
<!--T:2-->
uname -m
Firefox can be installed using the package '''firefox''' in your favorite package manager or using the command:
If the output is <code>x86_64</code>, you are using a 64bit installation.
{{UserCmd|command=pamac install firefox}}


=Other Versions= <!--T:3-->


2. Download the latest Firefox in your language from here: https://www.mozilla.org/en-US/firefox/all/
<!--T:4-->
{| class="wikitable"
! Package Name !! Source !! URL !! Description
|-
| firefox-developer-edition || repo || https://www.mozilla.org/firefox/channel/#developer || Official Developer Edition builds
|-
| firefox-nightly || aur || https://www.mozilla.org/en-US/firefox/nightly || Official Nightly builds
|-
| firefox-kde-opensuse || aur || https://build.opensuse.org/package/show/mozilla:Factory/MozillaFirefox || OpenSUSE's version of Firefox includes appmenu integration and native plasma integration
|-
| firefox-appmenu || aur || https://aur.archlinux.org/packages/firefox-appmenu/ || Unofficial Firefox build with appmenu patches added
|-
| firefox-esr || aur || https://www.mozilla.org/en-US/firefox/organizations/ || Official ESR releases.  This is the oldest supported version of Firefox
|}


Download "Linux", if you are using a 32bit installation of Manjaro or "Linux 64-bit" if your installation of Manjaro is 64bit.
=Dealing with dark GTK themes= <!--T:5-->


<!--T:6-->
Some pages will be hard to read when using dark gtk themes.  There are a few different ways to handle this:
* The most flexible way is to install the add-on [https://addons.mozilla.org/en-US/firefox/addon/text-contrast-for-dark-themes Text Contrast for Dark Themes] which will allow you to keep your theming but adjust it on a per page basis as needed


3. Unpack/extract the downloaded <code>firefox-xx.x.tag.bz2</code> file to
<!--T:7-->
  ~/bin/
* A simpler way is Preferences->Language & Appearance->Colors and uncheck "Use System Colors"The downside of this approach is that Firefox will no longer use a dark theme.
If a <code>bin</code> folder in your <code>home directory</code> does not exist, create it.


<!--T:8-->
* We can use css to force white backgrounds with dark text and controls by editing or creating ''~/.mozilla/profile.default/chrome/userContent.css'' with the following content:


<!--T:9-->
input:not(.urlbar-input):not(.textbox-input):not(.form-control):not([type='checkbox']):not([type='radio']), textarea, select {
    -moz-appearance: none !important;
    background-color: white;
    color: black;
}
#downloads-indicator-counter {
    color: white;
}
=Plasma Integration= <!--T:10-->
==Installing plasma Browser Integration== <!--T:11-->
<!--T:12-->
The [https://community.kde.org/Plasma/Browser_Integration browser integration package] provides media controls, notifications and integration with krunner.  You can install it with:
{{UserCmd|command=pamac install plasma-browser-integration}}
<!--T:13-->
Next install the [https://addons.mozilla.org/en-US/firefox/addon/plasma-integration plasma integration add-on] in Firefox.
==Using the native file chooser== <!--T:14-->
<!--T:15-->
It is possible to integrate the file chooser from plasma into Firefox giving you a more seamless experience.
<!--T:16-->
First ensure to install the packages xdg-desktop-portal and xdg-desktop-portal-kde using the command:
</translate>
{{UserCmd|command=pamac install xdg-desktop-portal xdg-desktop-portal-kde}}
<translate>
<!--T:17-->
Now we need to create a customized desktop launcher by creating a copy of the distribution file with
</translate>
{{UserCmd|command=mkdir -p ~/.local/share/applications}}
{{UserCmd|command=cp /usr/share/applications/firefox.desktop ~/.local/share/applications/}}
<translate>
<!--T:18-->
Next we need to edit the newly created file at ~/.local/share/applications/firefox.desktop using a [[Viewing_and_editing_configuration_files|text editor]]
<!--T:19-->
There are 3 edits that need to made to this file.
<!--T:20-->
replace:
</translate>
Exec=/usr/lib/firefox/firefox %u
<translate>
with:
</translate>
Exec=/usr/bin/sh -c "GTK_USE_PORTAL=1 /usr/lib/firefox/firefox %u"
<translate>
<!--T:21-->
replace:
</translate>
Exec=/usr/lib/firefox/firefox --new-window %u
<translate>
with:
</translate>
Exec=/usr/bin/sh -c "GTK_USE_PORTAL=1 /usr/lib/firefox/firefox --new-window %u"
<translate>
<!--T:22-->
replace:
</translate>
Exec=/usr/lib/firefox/firefox --private-window %u
<translate>
with:
</translate>
Exec=/usr/bin/sh -c "GTK_USE_PORTAL=1 /usr/lib/firefox/firefox --private-window %u"
<translate>
<!--T:23-->
Save and enjoy your Firefox-Plasma integration
=Installing Firefox directly from the Mozilla Website= <!--T:24-->
<!--T:25-->
Generally it is better to use the version of Firefox that is available in the repos but installing Firefox directly has one advantage: Firefox will update itself automatically as soon as an update is available.
This is great for users, who want to get the latest update as soon as possible without waiting for the next Manjaro update.
==Download Firefox from Mozilla== <!--T:26-->
<!--T:27-->
Download the latest Firefox in your language from here: https://www.mozilla.org/en-US/firefox/all/
<!--T:28-->
Most users will download "Linux 64-bit" in your chosen language.  If you are using manjaro32, download "Linux 32-bit"
==Extract the files== <!--T:29-->
<!--T:30-->
Ensure that '''~/bin''' exists with
{{UserCmd|command=mkdir -p ~/bin}}
<!--T:31-->
Unpack/extract the downloaded <code>firefox-xx.x.tar.bz2</code> file to ''~/bin/'' using a graphical tool or with the ''tar'' command.  Here is an example:
{{UserCmd|command=tar -xf ~/Downloads/firefox-66.0.5.tar.bz2 --directory ~/bin}}
<!--T:32-->
You can now start to use Firefox by double clicking on the file (or executing it in a terminal):
You can now start to use Firefox by double clicking on the file (or executing it in a terminal):
~/bin/firefox/firefox
{{UserCmd|command=~/bin/firefox/firefox}}




4. Let's create an icon in order to start Firefox much more easily:
==Create an icon== <!--T:33-->
create an firefox.desktop file and edit it:
sudo kwrite ~/.local/share/applications/firefox.desktop
(Instead of <code>kwrite</code>, use your preferred text editor: e.g. leafpad, gedit, mousepad, juffed, etc.)
(Every file name beginning with a <code>.</code> is a hidden file)


<!--T:34-->
Let's create an icon in order to start Firefox much more easily.


<!--T:35-->
Create an empty file
{{UserCmd|command=mkdir -p ~/.local/share/applications}}
{{UserCmd|command=touch ~/.local/share/applications/firefox.desktop}}
<!--T:36-->
Edit the file ''~/.local/share/applications/firefox.desktop'' in your favorite editor.  For a list of common editors see [[Viewing_and_editing_configuration_files|this page]]
<!--T:37-->
Copy and paste the following code into your <code>firefox.desktop</code> file and save it:
Copy and paste the following code into your <code>firefox.desktop</code> file and save it:
  [Desktop Entry]
  [Desktop Entry]
Line 40: Line 175:
  StartupNotify=false
  StartupNotify=false


 
<!--T:38-->
Now, you can click the <code>firefox.desktop</code> file and your Firefox will start. Create links of your <code>firefox.desktop</code> file or copy it to the place you prefer. You should also be able to start Firefox from your start menu now (after a reboot of your system).
In most Desktop Environments(DEs), Firefox will now be added to the menu. In some DEs you can click on the desktop to launch the application as well.
 
 
=More=
 
This method works for firefox-beta, firefox-aurora, and firefox-nightly, too. unfortunately, Firefox' own updater does not update to the next major version (e.g. from Firefox 33.0 to Firefox 34.0) for all these pre-stable releases of Firefox. The next major version needs to be downloaded and unpacked/extracted manually every time a new major update of Firefox is released.
 
 
This post is based on the following sources:
* https://www.youtube.com/watch?v=3oLon1m3vl0
* https://forum.manjaro.org/index.php?topic=16206.msg151149#msg151149




There is a forum entry for this post: https://forum.manjaro.org/index.php?topic=16246.0
=See also= <!--T:39-->


<!--T:40-->
* [https://wiki.archlinux.org/index.php/Firefox The arch wiki page]
* [[Internet_Browsers|Internet Browsers wiki page]]
</translate>


More Tips [https://wiki.manjaro.org/index.php?title=Internet_Browsers here]
[[Category:Contents Page{{#translation:}}]]

Latest revision as of 11:47, 22 May 2024

Other languages:
Deutsch • ‎English • ‎español • ‎español de América Latina • ‎français • ‎русский • ‎فارسی • ‎中文(中国大陆)‎

Installing Firefox

Firefox can be installed using the package firefox in your favorite package manager or using the command:

user $ pamac install firefox COPY TO CLIPBOARD


Other Versions

Package Name Source URL Description
firefox-developer-edition repo https://www.mozilla.org/firefox/channel/#developer Official Developer Edition builds
firefox-nightly aur https://www.mozilla.org/en-US/firefox/nightly Official Nightly builds
firefox-kde-opensuse aur https://build.opensuse.org/package/show/mozilla:Factory/MozillaFirefox OpenSUSE's version of Firefox includes appmenu integration and native plasma integration
firefox-appmenu aur https://aur.archlinux.org/packages/firefox-appmenu/ Unofficial Firefox build with appmenu patches added
firefox-esr aur https://www.mozilla.org/en-US/firefox/organizations/ Official ESR releases. This is the oldest supported version of Firefox

Dealing with dark GTK themes

Some pages will be hard to read when using dark gtk themes. There are a few different ways to handle this:

  • The most flexible way is to install the add-on Text Contrast for Dark Themes which will allow you to keep your theming but adjust it on a per page basis as needed
  • A simpler way is Preferences->Language & Appearance->Colors and uncheck "Use System Colors". The downside of this approach is that Firefox will no longer use a dark theme.
  • We can use css to force white backgrounds with dark text and controls by editing or creating ~/.mozilla/profile.default/chrome/userContent.css with the following content:
input:not(.urlbar-input):not(.textbox-input):not(.form-control):not([type='checkbox']):not([type='radio']), textarea, select {
    -moz-appearance: none !important;
    background-color: white;
    color: black;
}

#downloads-indicator-counter {
    color: white;
}


Plasma Integration

Installing plasma Browser Integration

The browser integration package provides media controls, notifications and integration with krunner. You can install it with:

user $ pamac install plasma-browser-integration COPY TO CLIPBOARD


Next install the plasma integration add-on in Firefox.


Using the native file chooser

It is possible to integrate the file chooser from plasma into Firefox giving you a more seamless experience.

First ensure to install the packages xdg-desktop-portal and xdg-desktop-portal-kde using the command:

user $ pamac install xdg-desktop-portal xdg-desktop-portal-kde COPY TO CLIPBOARD


Now we need to create a customized desktop launcher by creating a copy of the distribution file with

user $ mkdir -p ~/.local/share/applications COPY TO CLIPBOARD


user $ cp /usr/share/applications/firefox.desktop ~/.local/share/applications/ COPY TO CLIPBOARD


Next we need to edit the newly created file at ~/.local/share/applications/firefox.desktop using a text editor

There are 3 edits that need to made to this file.

replace:

Exec=/usr/lib/firefox/firefox %u

with:

Exec=/usr/bin/sh -c "GTK_USE_PORTAL=1 /usr/lib/firefox/firefox %u"

replace:

Exec=/usr/lib/firefox/firefox --new-window %u
with:
Exec=/usr/bin/sh -c "GTK_USE_PORTAL=1 /usr/lib/firefox/firefox --new-window %u"

replace:

Exec=/usr/lib/firefox/firefox --private-window %u

with:

Exec=/usr/bin/sh -c "GTK_USE_PORTAL=1 /usr/lib/firefox/firefox --private-window %u"

Save and enjoy your Firefox-Plasma integration

Installing Firefox directly from the Mozilla Website

Generally it is better to use the version of Firefox that is available in the repos but installing Firefox directly has one advantage: Firefox will update itself automatically as soon as an update is available. This is great for users, who want to get the latest update as soon as possible without waiting for the next Manjaro update.


Download Firefox from Mozilla

Download the latest Firefox in your language from here: https://www.mozilla.org/en-US/firefox/all/

Most users will download "Linux 64-bit" in your chosen language. If you are using manjaro32, download "Linux 32-bit"


Extract the files

Ensure that ~/bin exists with

user $ mkdir -p ~/bin COPY TO CLIPBOARD


Unpack/extract the downloaded firefox-xx.x.tar.bz2 file to ~/bin/ using a graphical tool or with the tar command. Here is an example:

user $ tar -xf ~/Downloads/firefox-66.0.5.tar.bz2 --directory ~/bin COPY TO CLIPBOARD


You can now start to use Firefox by double clicking on the file (or executing it in a terminal):

user $ ~/bin/firefox/firefox COPY TO CLIPBOARD



Create an icon

Let's create an icon in order to start Firefox much more easily.

Create an empty file

user $ mkdir -p ~/.local/share/applications COPY TO CLIPBOARD


user $ touch ~/.local/share/applications/firefox.desktop COPY TO CLIPBOARD


Edit the file ~/.local/share/applications/firefox.desktop in your favorite editor. For a list of common editors see this page

Copy and paste the following code into your firefox.desktop file and save it:

[Desktop Entry]
Name=Firefox
GenericName=Web Browser
Icon=~/bin/firefox/browser/icons/mozicon128.png
Type=Application
Categories=Application;Network;WebBrowser;
Exec=~/bin/firefox/firefox
Terminal=false
StartupNotify=false

In most Desktop Environments(DEs), Firefox will now be added to the menu. In some DEs you can click on the desktop to launch the application as well.


See also

Cookies help us deliver our services. By using our services, you agree to our use of cookies.