Chromium/Tips and tricks

From ArchWiki
< Chromium
Revision as of 20:47, 8 December 2011 by Graysky (Talk | contribs) (Created page with "== Browsing Experience == === Broken Icons in Download Tab === You may find that Chromium shows icon placeholders (icons representing broken documents) instead of appropriate...")

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Browsing Experience

Broken Icons in Download Tab

You may find that Chromium shows icon placeholders (icons representing broken documents) instead of appropriate icons in its download tab. The likely cause is that you have not installed a desktop environment.

Remedy this by installing GNOME icons:

# pacman -S gnome-icon-theme

Experimental Features

To enable experimental features of Chromium like WebGL and rendering webpages with the GPU, type "about:flags" in the Chromium address bar and enable features you want.

Link file manager to "Show in folder" function

When you are using a window manager such as Openbox in combination with a file manager like Thunar instead of a DE, this function of Chromium may only show the directory tree inside Chromium. However to show the file in the folder using your file manager instead, install Template:Filename.

Memory Usage

  • Chromium offers some command-line options to help control how efficient it is with system memory, by determining how often it should release memory back to the operating system. It is done with the flag --memory-model=X, where X is either high, medium, or low. Setting it to high makes chromium never release memory. Medium makes it reduce its working set of the memory when switching tabs, and low makes it reduce its working set when switching tabs and when the browser is not actively being used. In my experience, running chromium with --memory-model=low can actually improve performance as well, though your mileage may vary. --Falcata 06:07, 26 November 2010 (EST)

Scroll Speed of Wheel Mouse

Adjust the scroll speed of the wheel mouse via the --scroll-pixels= switch Example:

$ chromium --scroll-pixels=200

Search Engines

You can make sites like wiki.archlinux.org and wikipedia.org easily searchable by first executing a search on those pages, then going to Options>Preferences>Basics and clicking "Manage" in the "Default Search" section. You can then, for example, "Edit" the Wikipedia entry and change its keyword to "w". Then, you can search Wikipedia for "Arch Linux" from the address bar by simply entering "w arch linux". "?" is a hard-coded keyword for Google search (it will behave differently from the other keywords). It allows you to easily search for things like "/bin/bash".

Tmpfs

Cache in tmpfs

Note: Chromium actually keeps its cache directory separate from its browser profile directory.

To limit Chromium from writing its cache to a physical disk, one can define an alternative location via the --disk-cache-dir=/foo/bar flag:

$ chromium --disk-cache-dir=/tmp/cache

Alternatively, one can create a symlink to an alternative location in ~/.cache

$ mv ~$HOME/.cache/chromium /tmp/cache && ln -s $HOME/.cache/chromium /tmp/cache

In both cases, the cache should be considered temporary and will NOT be saved after a reboot or hard lock.

Profile in tmpfs

Relocate the browser profile to tmpfs filesystem, including Template:Filename, or Template:Filename for improvements in application response as the the entire profile is now stored in RAM. Another benefit is a reduction in disk read and write operations, of which SSDs benefit the most.

Use an active management script for maximal reliability and ease of use. Several are available from the AUR.

User Agent

By default Chromium already sends an excessively detailed User Agent, as is viewable via the EFF's Panopticlick test. That alone makes each browser readily identifiable with high accuracy — and is further exacerbated by the use of non-stable versions, ones not recently provided by Google's release channels, ones customized e. g. by a distribution (such as the AUR's chromium-browser-ppa) etc.

However, this User Agent can be arbitrarily modified at the start of Chromium's base instance via its Template:Codeline parameter.

For the same User Agent as the stable Chrome release for Linux x64 (at the time of writing) one would use:

--user-agent="Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.2 (KHTML, like Gecko) Chrome/15.0.874.106 Safari/535.2"

Security

Run in a Sandbox

Run chromium in a sandbox for added security. Example:

$ chromium --enable-seccomp-sandbox