Linux firefox fonts like windows

Содержание
  1. Шрифты Firefox в Linux как в Windows
  2. Re: Шрифты Firefox в Linux как в Windows
  3. Re: Шрифты Firefox в Linux как в Windows
  4. Re: Шрифты Firefox в Linux как в Windows
  5. Re: Шрифты Firefox в Linux как в Windows
  6. Re: Шрифты Firefox в Linux как в Windows
  7. Re: Шрифты Firefox в Linux как в Windows
  8. Re: Шрифты Firefox в Linux как в Windows
  9. Re: Шрифты Firefox в Linux как в Windows
  10. Re: Шрифты Firefox в Linux как в Windows
  11. Re: Шрифты Firefox в Linux как в Windows
  12. Re: Шрифты Firefox в Linux как в Windows
  13. Re: Шрифты Firefox в Linux как в Windows
  14. Re: Шрифты Firefox в Linux как в Windows
  15. Re: Шрифты Firefox в Linux как в Windows
  16. Re: Шрифты Firefox в Linux как в Windows
  17. Re: Шрифты Firefox в Linux как в Windows
  18. Re: Шрифты Firefox в Linux как в Windows
  19. Firefox/Tweaks
  20. Contents
  21. Performance
  22. Change Performance settings
  23. Enable WebRender compositor
  24. Enable Legacy OpenGL compositor
  25. Stop urlclassifier3.sqlite from being created again
  26. Turn off the disk cache
  27. Move disk cache to RAM
  28. Longer interval between session information record
  29. Defragment the profile’s SQLite databases
  30. Cache the entire profile into RAM via tmpfs
  31. Disable Pocket
  32. Appearance
  33. Fonts
  34. Configure the DPI value
  35. Default font settings from Microsoft Windows
  36. General user interface CSS settings
  37. Change the interface font
  38. Hide button icons
  39. Hiding various tab buttons
  40. Horizontal tabs
  41. Hide title bar and window border
  42. Auto-hide Bookmarks Toolbar
  43. Remove sidebar width restrictions
  44. Unreadable input fields with dark GTK themes
  45. Web content CSS settings
  46. Import other CSS files
  47. Block certain parts of a domain
  48. Add [pdf] after links to PDF files
  49. Block ads
  50. Mouse and keyboard
  51. Mouse wheel scroll speed
  52. Pixel-perfect trackpad scrolling
  53. Enable touchscreen gestures
  54. Mouse click on URL bar’s behavior
  55. Smooth scrolling
  56. Set backspace’s behavior
  57. Disable middle mouse button clipboard paste
  58. Emacs key bindings
  59. Miscellaneous
  60. Force-enable hardware video decoding
  61. Remove full screen warning
  62. Change the order of search engines in the Firefox Search Bar
  63. «I’m Feeling Lucky» mode
  64. Secure DNS with DNSSEC validator
  65. Secure DNS with DNS over HTTPS
  66. Adding magnet protocol association
  67. Prevent accidental closing
  68. Plugins do not work with latest version
  69. Jerky or choppy scrolling
  70. Run Firefox inside an nspawn container
  71. Disable WebRTC audio post processing
  72. Fido U2F authentication
  73. Get ALSA working back
  74. Force-enable WebGL

Шрифты Firefox в Linux как в Windows

Народ как сделать что-бы в Firefox 1.5 в Linux, были такие же шрифты как в Windows? Долго работал в firefox под Windows, и очень привык. в Linux что-то да не так, хотя поставил пакет шрифтов от MS, выставил в firefox точно также как в Windows.

Re: Шрифты Firefox в Linux как в Windows

Re: Шрифты Firefox в Linux как в Windows

Отключить сглаживание для мелких шрифтов, а если будут смотреться плохо — пересобрать Freetype с поддержкой BCI.

Re: Шрифты Firefox в Linux как в Windows

и про dpi не забывать

Re: Шрифты Firefox в Linux как в Windows

что такое dpi? его нужно включить?

Re: Шрифты Firefox в Linux как в Windows

Re: Шрифты Firefox в Linux как в Windows

Да. О, мой конфиг в факе))

Re: Шрифты Firefox в Linux как в Windows

Там правда опечатка есть почему-то.

Вот правильный вариант:

Re: Шрифты Firefox в Linux как в Windows

Хе, спасибо за конфиг! ;))

Re: Шрифты Firefox в Linux как в Windows

а как именно отключить сглаживание мелких шрифтов? Я пересобрал ttf, с поддержкой сглаживания, но маленькие шрифты, (особенно bold) выглядят не очень.

Re: Шрифты Firefox в Linux как в Windows

Воспользуйся ссылкой выше

Re: Шрифты Firefox в Linux как в Windows

Re: Шрифты Firefox в Linux как в Windows

пересобрал ttf , включил dpi96x96 + config выше в итоге получилось http://img225.imageshack.us/my.php?image=screenshot7df.png почему так? что делаю неправильно?

Re: Шрифты Firefox в Linux как в Windows

Все разобрался, теперь все ok, косяк был в том что я собранные ttf шрифты устанавливал поверх rpm’шных

Re: Шрифты Firefox в Linux как в Windows

Интересно, как можно пересобирать шрифты?!

В Федоре нужно просто скачать src.rpm freetype и, поправив одну цифру в .spec’e, пересобрать.

Re: Шрифты Firefox в Linux как в Windows

очень просто берешь из http://corefonts.sourceforge.net/ правишь
freetype-2.x.x/include/freetype/config/ftoption.h
#undef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
на #define TT_CONFIG_OPTION_BYTECODE_INTERPRETER и собираешь. вообще-то это из FAQ куда ты меня направил 😉

Re: Шрифты Firefox в Linux как в Windows

я незнаю почему но у меня с этим конфигом по всему GNOME пропадают шрифты появляются только когда на них наводишь мышкой. почему так?

Re: Шрифты Firefox в Linux как в Windows

что-то сильно хуже стало.. откатываю назад. может это не для 120DPI.

Источник

Firefox/Tweaks

This article or section is a candidate for merging with Firefox#Tips and tricks.

This page contains advanced Firefox configuration options and performance tweaks.

Contents

Performance

Improving Firefox’s performance is divided into parameters that can be inputted while running Firefox or otherwise modifying its configuration as intended by the developers, and advanced procedures that involve foreign programs or scripts.

This section contains advanced Firefox options for performance tweaking. For additional information see these MozillaZine articles.

Change Performance settings

Firefox automatically uses settings based on the computer’s hardware specifications [1].

Adjusting these settings can be done in Preferences or by changing the dom.ipc.processCount value to 1-8 and browser.preferences.defaultPerformanceSettings.enabled to false manually in about:config .

However you may want to manually adjust this setting to increase performance even further or decrease memory usage on low-end devices.

In this case the Content process limit for the current user has been increased to 4:

Enable WebRender compositor

WebRender is a GPU based 2D rendering engine written in Rust. It is the compositor that powers the Servo browser engine project, instead of the Gecko compositor. It improves performance on supported hardware, fixes some black visual glitches when the OpenGL compositor is used. Currently it has some known bugs. You can read more in MozillaWiki:Platform/GFX/Quantum Render.

WebRender is enabled by default on all wayland sessions (as of Firefox 89) [2]. WebRender is also enabled by default for non 4k+ displays. In some edge cases qualifications can change as detailed in MozillaWiki:Platform/GFX/WebRender Where#Linux. Default WebRender enablement could also depend on the graphics card or driver versions.

Читайте также:  Asus z99 windows 10

One can force-enable it using one of the two methods below:

  1. by going to about:config and setting gfx.webrender.all to true . Restart Firefox for changes to take effect.
  2. by setting the MOZ_WEBRENDER environment variable to 1 before launching Firefox.

To check if WebRender is enabled, go to about:support and under the «Graphics» section, in the «Decision Log» sub-section, look for «WEBRENDER». If it reports «available by user: Force enabled by pref», it means is enabled. If it only reports «opt-in by default: WebRender is an opt-in feature», it means it is disabled.

Enable Legacy OpenGL compositor

Hardware WebRender or the software Basic compositor is used by default. To check if the legacy OpenGL compositor is running, go to about:support and under the «Graphics» section look for «Compositing»: if it reports «OpenGL», it is enabled, otherwise it reports «WebRender» or «Basic».

OpenGL composition can be force-enabled by going to about:config and switching layers.acceleration.force-enabled to true . Restart Firefox for the change to take effect. Note WebRender is the replacement for Firefox’s OpenGL compositor, and is recommended over the OpenGL compositor.

Stop urlclassifier3.sqlite from being created again

This article or section is out of date.

Removing all urlclassifier* files can prevent the use of megabytes of storage in your firefox profile. If you remove all the urlclassifier* files, you may find out that urlclassifier3.sqlite keeps growing again after a certain time. Here is a simple solution to avoid it for now and ever.

This effectively makes the file empty and then read-only so Firefox cannot write to it anymore.

Turn off the disk cache

Every object loaded (html page, jpeg image, css stylesheet, gif banner) is saved in the Firefox cache for future use without the need to download it again. It is estimated that only a fraction of these objects will be reused, usually about 30%. This is because of very short object expiration time, updates or simply user behavior (loading new pages instead of returning to the ones already visited). The Firefox cache is divided into memory and disk cache and the latter results in frequent disk writes: newly loaded objects are written to memory and older objects are removed.

An alternative approach is to use about:config settings:

  • Set browser.cache.disk.enable to false
  • Verify that browser.cache.memory.enable is set to true , more information about this option can be found in the browser.cache.memory Mozilla article
  • Add the entry (right click > new > integer) browser.cache.memory.capacity and set it to the amount of KB you want to spare, or to -1 for automatic cache size selection (skipping this step has the same effect as setting the value to -1 )
    • The «automatic» size selection is based on a decade-old table that only contains settings for systems at or below 8GB of system memory. The following formula very closely approximates this table, and can be used to set the Firefox cache more dynamically: 41297 — (41606 / (1 + ((RAM / 1.16) ^ 0.75))) , where RAM is in GB and the result is in KB.

This method has some drawbacks:

  • The content of currently browsed webpages is lost if the browser crashes or after a reboot, this can be avoided using anything-sync-daemon or any similar periodically-syncing script so that cache gets copied over to the drive on a regular basis
  • The settings need to be configured for each user individually

Move disk cache to RAM

An alternative is to move the «disk» cache to a RAM disk, giving you a solution in between the two above. The cache will now be preserved between Firefox runs (including Firefox crash recovery), but will be discarded upon reboot (including OS crash).

To do this, go to about:config and set browser.cache.disk.parent_directory to /run/user/UID/firefox , where UID is your user’s ID which can be obtained by running id -u .

Open about:cache to verify the new disk cache location.

Longer interval between session information record

Firefox stores the current session status (opened urls, cookies, history and form data) to the disk on a regular basis. It is used to recover a previous session in case of crash. The default setting is to save the session every 15 seconds, resulting in frequent disk access.

To increase the save interval to 10 minutes (600000 milliseconds) for example, change in about:config the setting of browser.sessionstore.interval to 600000

To disable completely this feature, change browser.sessionstore.resume_from_crash to false .

Defragment the profile’s SQLite databases

Firefox keeps bookmarks, history, passwords in SQLite databases. SQLite databases become fragmented over time and empty spaces appear all around. But, since there are no managing processes checking and optimizing the database, these factors eventually result in a performance hit. A good way to improve start-up and some other bookmarks and history related tasks is to defragment and trim unused space from these databases.

You can use profile-cleaner to do this, while Firefox is not running:

profile-cleaner usage example:

SQLite database Size Before Size After % change
urlclassifier3.sqlite 37 M 30 M 19 %
places.sqlite 16 M 2.4 M 85 %

Firefox provides a tool to defragment and optimize the places database, which is the source of most slowdowns and profile corruptions. To access this tool, open the about:support page, search for Places Database and click the Verify Integrity button.

Cache the entire profile into RAM via tmpfs

If the system has memory to spare, tmpfs can be used to cache the entire profile directory, which might result in increased Firefox responsiveness.

Disable Pocket

If you do not use the Pocket-service, you may want to disable it by setting extensions.pocket.enabled to false in about:config .

Appearance

Fonts

Configure the DPI value

Modifying the following value can help improve the way fonts looks in Firefox if the system’s DPI is below 96. Firefox, by default, uses 96 and only uses the system’s DPI if it is a higher value. To force the system’s DPI regardless of its value, type about:config into the address bar and set layout.css.dpi to 0.

Note that the above method only affects the Firefox user interface’s DPI settings. Web page contents still use a DPI value of 96, which may look ugly or, in the case of high-resolution displays, may be rendered too small to read. A solution is to change layout.css.devPixelsPerPx to system’s DPI divided by 96. For example, if your system’s DPI is 144, then the value to add is 144/96 = 1.5. Changing layout.css.devPixelsPerPx to 1.5 makes web page contents use a DPI of 144, which looks much better.

Читайте также:  Долго загружаются файлы при установке windows

See also HiDPI#Firefox for information about HiDPI displays and [3] for calculating the DPI.

Default font settings from Microsoft Windows

Below are the default font preferences when Firefox is installed in Microsoft Windows. Many web sites use the Microsoft fonts.

General user interface CSS settings

Firefox’s user interface can be modified by editing the userChrome.css and userContent.css files in

/chrome/ (profile_dir is of the form hash.name, where the hash is an 8 character, seemingly random string and the profile name is usually default). You can find out the exact name by typing about:support in the URL bar, and searching for the Profile Directory field under the Application Basics section as described in the Firefox documentation.

This section only deals with the userChrome.css file which modifies Firefox’s user interface, and not web pages.

Change the interface font

The setting effectively overrides the global GTK font preferences, and does not affect webpages, only the user interface itself:

Hide button icons

Enables text-only buttons:

Hiding various tab buttons

These settings hide the arrows that appear to the horizontal edges of the tab bar, the button that toggles the «all tabs» drop-down list, and the plus sign button that creates a new tab.

Horizontal tabs

To place the tab bar horizontally stacked along the sides of the browser window:

Hide title bar and window border

To replace the title bar with the tab bar, enable browser.tabs.drawInTitlebar in about:config .

Or go to «Menu», then «Customize» and then at the bottom-left corner find checkbox named «Title Bar». Uncheck it. If the checkbox is missing, make sure the XDG_CURRENT_DESKTOP environment variable is correctly set and/or the MOZ_GTK_TITLEBAR_DECORATION environment variable is set to «client».

Hide only title bar in KDE

With the setting above, Firefox adds in KDE the minimize/macimize/close buttons to the tab bar, but the title bar will still be there.

It can be removed by right-clicking on it, then More Actions > Configure Special Application Settings. Add a new property there for «No titlebar and frame» and be sure to not forget activating it, «Yes» must be chosen. (As you have now no titlebar anymore there, to later change the rule, you can go to System Settings > Window Management > Window Rules.)

However, that will also remove the frame, it is basically impossible to change the window size. An alternative is go to System settings > Application Style > Window Decorations, choose «Breeze» and change its settings. In the last tab, Window-Specific Overrides, add a new one. Use the button Detect Window Properties to get the name. There is a button Detect Window Properties. Alternatively, if you want to set this override for all windows, not just Firefox, you can enter a dot (.) in the regex field. Afterwards, set the Decoration Options to hide the title bar only.

Auto-hide Bookmarks Toolbar

Remove sidebar width restrictions

Unreadable input fields with dark GTK themes

When using a dark GTK theme, one might encounter Internet pages with unreadable input and text fields (e.g. text input field with white text on white background, or black text on dark background). This can happen because the site only sets either background or text color, and Firefox takes the other one from the theme. To prevent Firefox from using theme’s colors and dark themes in web pages respectively confirm browser.display.use_system_colors and widget.content.allow-gtk-dark-theme are set to false in about:config .

Otherwise, if the previous modification did not solve the issue, it is possible to launch Firefox with a light GTK theme by adding a new string in about:config named widget.content.gtk-theme-override and setting it to a light theme like Breeze:light or Adwaita:light .

Override input field color with CSS

The extension Text Contrast for Dark Themes sets the other color as needed to maintain contrast.

Alternatively set the standard colors explicitly for all web pages in userContent.css or using the stylus add-on. The style sheet is usually located in your profile folder (visit about:profiles for the path) in chrome/userContent.css , if not you can create it there.

The following sets input fields to standard black text / white background; both can be overridden by the displayed site, so that colors are seen as intended:

Change the GTK theme

To force Firefox to use a light theme (e.g. Adwaita) for both web content and UI, see GTK#Themes.

Change the GTK theme for content process only

To force Firefox to use a light theme (e.g. Adwaita) for web content only:

  1. Open about:config in the address bar.
  2. Create a new widget.content.gtk-theme-override string type entry ( right mouse button > New > String).
  3. Set the value to the light theme to use for rendering purposes (e.g. Adwaita:light ).
  4. Restart Firefox.

Web content CSS settings

This section deals with the userContent.css file in which you can add custom CSS rules for web content. Changes to this file will take effect once the browser is restarted.

This file can be used for making small fixes or to apply personal styles to frequently visited websites. Custom stylesheets for popular websites are available from sources such as userstyles.org. You can install an add-on such as superUserContent [dead link 2020-03-29 ⓘ] to manage themes. This add-on creates the directory chrome/userContent.css.d and applies changes to the CSS files therein when the page is refreshed.

Import other CSS files

Block certain parts of a domain

Block ads

See floppymoose.com for an example of how to use userContent.css as a basic ad-blocker.

Mouse and keyboard

Mouse wheel scroll speed

To modify the default values (i.e. speed-up) of the mouse wheel scroll speed, go to about:config and search for mousewheel.acceleration . This will show the available options, modifying the following:

  • Set mousewheel.acceleration.start to 1 .
  • Set mousewheel.acceleration.factor to the desired number ( 10 to 20 are common values).
Читайте также:  Драйвера для hp laserjet pro mfp m132nw для mac os

Mozilla’s recommendation for increasing the mousewheel scroll speed is to:

  • Set mousewheel.default.delta_multiplier_y between 200 and 500 (default: 100 )

Pixel-perfect trackpad scrolling

To enable one-to-one trackpad scrolling (as can be witnessed with GTK3 applications like Nautilus), set the MOZ_USE_XINPUT2=1 environment variable before starting Firefox.

If scrolling is undesirably jerky, try enabling Firefox’s Use smooth scrolling option under Preferences > General > Browsing.

Enable touchscreen gestures

Make sure dom.w3c_touch_events.enabled is either set to 1 (enabled) or 2 (default, auto-detect).

Add MOZ_USE_XINPUT2 DEFAULT=1 to /etc/security/pam_env.conf and then logout or reboot your system for the changes to take effect.

On some devices, it may be necessary to disable xinput’s touchscreen gestures by running the following:

Mouse click on URL bar’s behavior

To make the URL bar behave like in Windows regarding mouse clicks: a single click selects everything, a double click selects a single word until a punctuation sign and a triple click selects everything again, set the following in about:config :

Smooth scrolling

In order to get smooth physics-based scrolling in Firefox, the general.smoothScroll.msdPhysics configurations can be changed to emulate a snappier behaviour like in other web browsers. For a quicker configuration, append the following to

/.mozilla/firefox/your-profile/user.js (requires restart):

Additionally the mouse wheel scroll settings have to be changed to react in a smooth way as well:

If you have troubles on machines with varying performance, try modifying the mousewheel.min_line_scroll_amount until it feels snappy enough.

Set backspace’s behavior

Disable middle mouse button clipboard paste

Emacs key bindings

To have Emacs/Readline-like key bindings active in text fields, see GTK#Emacs key bindings.

Miscellaneous

Force-enable hardware video decoding

Although media.hardware-video-decoding.enabled is enabled by default, one may need to force-enable hardware video decoding by setting media.hardware-video-decoding.force-enabled to true .

Remove full screen warning

Warning about video displayed in full screen mode («… is now fullscreen») can be disabled by setting full-screen-api.warning.timeout to 0 in about:config .

Change the order of search engines in the Firefox Search Bar

To change the order search engines are displayed in:

  • Open the drop-down list of search engines and click Manage Search Engines. entry.
  • Highlight the engine you want to move and use Move Up or Move Down to move it. Alternatively, you can use drag-and-drop.

«I’m Feeling Lucky» mode

Some search engines have a «feeling lucky» feature. For example, Google has «I’m Feeling Lucky», and DuckDuckGo has «I’m Feeling Ducky».

To activate them, search for keyword.url in about:config and modify its value (if any) to the URL of the search engine.

For Google, set it to:

For DuckDuckGo, set it to:

Secure DNS with DNSSEC validator

You can enable DNSSEC support for safer browsing.

Secure DNS with DNS over HTTPS

Adding magnet protocol association

In about:config set network.protocol-handler.expose.magnet to false . In case it does not exist, it needs to be created, right click on a free area and select New > Boolean, input network.protocol-handler.expose.magnet and set it to false .

The next time you open a magnet link, you will be prompted with a Launch Application dialogue. From there simply select your chosen BitTorrent client. This technique can also be used with other protocols: network.protocol-handler.expose.

Prevent accidental closing

There are different approaches to handle this:

Since Firefox 87+ this behavior can be disabled with browser.quitShortcut.disabled property set to true in about:config

For pre-87 use these methods:

Under about:preferences#general select Warn you when quitting the browser .

An alternative is to add a rule in your window manager configuration file. For example in Openbox add:

in the section of your

The Disable Ctrl-Q and Cmd-Q extension can be installed to prevent unwanted closing of the browser.

Plugins do not work with latest version

There can be compatibility issues with plugins not working with the latest Firefox version (e.g. Pentadactyl). If possible, try installing the nightly/beta builds available, or temporarily downgrade Firefox.

Disable Add-on Compatibility Checks [dead link 2020-03-29 ⓘ] plugin should take care of spurious compatibility issues when the plugins get disabled, even though they work just fine with the new version.

Jerky or choppy scrolling

Scrolling in Firefox can feel «jerky» or «choppy». A post on MozillaZine gives settings that work on Gentoo, but reportedly work on Arch Linux as well:

  1. Set mousewheel.min_line_scroll_amount to 40
  2. Set general.smoothScroll and general.smoothScroll.pages to false
  3. Set image.mem.min_discard_timeout_ms to something really large such as 2100000000 but no more than 2140000000. Above that number Firefox will not accept your entry and complain with the error code: «The text you entered is not a number.»
  4. Set image.mem.max_decoded_image_kb to at least 512K

Now scrolling should flow smoothly.

Run Firefox inside an nspawn container

Disable WebRTC audio post processing

If you are using the PulseAudio PulseAudio#Microphone echo/noise cancellation, you probably do not want Firefox to do additional audio post processing.

To disable audio post processing, change the value of the following preferences to false :

  • media.getusermedia.aec_enabled (Acoustic Echo Cancellation)
  • media.getusermedia.agc_enabled (Automatic Gain Control)
  • media.getusermedia.noise_enabled (Noise suppression)
  • media.getusermedia.hpf_enabled (High-pass filter)

Fido U2F authentication

Firefox supports the Fido U2F authentication protocol. Install libfido2 for the required udev rules.

Get ALSA working back

As long as Arch keeps building Firefox with ac_add_options —enable-alsa, then Firefox works fine without pulse on the system, without needing any special configurations, and without apulse (unless using pulse on the system and wanting Firefox to avoid using it). It used to be one had to allow ioctl syscalls, blocked by default by Firefox sandboxing, and required by ALSA setting security.sandbox.content.syscall_whitelist in about:config , to the right ioctl syscall number, which is 16 for x86-64 and 54 for x86-32, but not anymore. For reference, see:

Force-enable WebGL

On some platforms WebGL may be disabled even when the user desires to use it. To force-enable WebGL set webgl.force-enabled to true , to also force-enable WebGL anti-aliasing, set webgl.msaa-force to true .

If you get an error similar to this:

then you can try the solution explained in Firefox bug 1480755 [8]:

Источник

Оцените статью