Codeblocks not rendering correctly in firefox

i have no problems with chrome but when I pull up some of the websites that have no problem loading up in chrome on firefox I get those half-cut codeblocks, not sure how to fix this, any advice would be deeply appreciated!

these are my font settings in firefox :point_down:

Hi @Mmshukla21,

I use Firefox, thatā€™s all I use, and I have no such problems. The are my Firefox font settings if you wish to try:

I tried those settings, made everything default but have a look at this, this is how it renders codeblocks for me :frowning:

And yet, mine is perfectly fine.

  • Have you tried a new, clean profile?

  • Have you tries turning off any plugins?


just created this new profile. have no extra plugins installed other than the default ones!

Ergh.

The last thing I can recommend is that you check your system fonts:

If itā€™s not that, I am all out of ideas.


theyā€™re already set to their default settings I didnā€™t touch em
Iā€™m thinking of reinstalling firefox by completely deleting any leftover config files, if would be great if you guide me through the first few steps, I donā€™t know exactly where all those files are located.

AFAIK itā€™ll be the following:

  • Remove Firefox:
pamac remove firefox
  • Move the Mozilla configuration files in your home directory:
mv ~/.mozilla ~/.mozilla.backup
  • Reinstall Firefox, overwriting any conflicts:
pamac install firefox --overwrite='*'

And set everything up again.

You could also just exit Firefox, (re)move tyhe config, and restart Firefox. Should have the same effect.

If you encounter any problems, you can just restore the backup:

cp ~/.mozilla.backup ~/.mozilla

If not, feel free to delete the old, faulty directory:

rm -fr ~/.~/.mozilla.backup

Note:

This is going to cause your Firefox to be completely reset, so no auto-logins, extensions, themes, saved passwords, or anything else custom will be kept.

I have backed up passwords and bookmarks

itā€™s already in the home directory

[sudo] password for manmohan: 
/home/manmohan/.mozilla
/home/manmohan/.local/share/torbrowser/tbb/x86_64/tor-browser_en-US/Browser/TorBrowser/Data/Browser/.mozilla
find: ā€˜/run/user/1000/docā€™: Permission denied
find: ā€˜/run/user/1000/gvfsā€™: Permission denied

reinstalled firefox still getting the same error


:sob: :sob:

Just a few ideas that popped up in my head while reading the thread.
From the world of typography, I would call this error wrong font size for the desired line spacing, almost as if there was a setting to, e.g. like in LibreOffice Writer, adjust line spacing to be smaller than the font size used, at which time the letters will interfere with the line above them. They sort of clash into one another, or, as in this case, they get cut off. Is there such a setting in Firefox, maybe? (Which, by the way, used to be abbreviated Fx, is it still?) Perhaps under the infamous about:config. In there is a setting ā€œdom.textMetrics.fontBoundingBox.enabledā€, mine says ā€œfalseā€, could be worth a try checking in there, not sure itā€™ll change anything for you, but perhaps you will find other, more useful things. Be careful, though! Donā€™t willy nilly double-click on things, the settings may change if you do.
Either that, or if some plug-in has done something with CSS/JavaScript (Tampermonkey/Stylus, etc.), or is there a default CSS document which is always loaded? Not sure if thatā€™s even a thing.
BTW, you have tried changing to a different font, right?
Good luck!
Post scriptum
Have you tried zooming out?

1 Like

didnā€™t work, I donā€™t wanna wipe my entire operating system just for this :pensive:

Are you using any type of scaling in KDEā€™s display settings?

nope I am not

posted this everywhere, havenā€™t got any reasonable answer yet

So to summarize so far:

:white_check_mark: Fresh Firefox profile (default settings, no extensions)

:white_check_mark: No scaling or DPI settings configured in KDE

:white_check_mark: Only happens with Firefox (no other browser)

:white_check_mark: Changing the fonts makes no difference

:white_check_mark: Zooming in and out makes no difference

Is that correct?

yes it is

Youā€™re using an Intel GPU? Can you post the system specs?

System:
  Kernel: 5.15.49-1-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 12.1.0
    parameters: BOOT_IMAGE=/boot/vmlinuz-5.15-x86_64
    root=UUID=6c041c4e-e9ca-4e70-9edc-6656731e29bd rw quiet apparmor=1
    security=apparmor resume=UUID=2ba2089c-de98-4caf-9c87-b60340f023ae
    udev.log_priority=3
  Desktop: KDE Plasma v: 5.24.5 tk: Qt v: 5.15.5 wm: kwin_x11 vt: 1 dm: SDDM
    Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Laptop System: ASUSTeK product: VivoBook_ASUSLaptop X512FAC_X512FA
    v: 1.0 serial: <superuser required>
  Mobo: ASUSTeK model: X512FAC v: 1.0 serial: <superuser required>
    UEFI: American Megatrends v: X512FAC.304 date: 01/26/2021
Battery:
  ID-1: BAT0 charge: 8.0 Wh (25.6%) condition: 31.3/37.1 Wh (84.4%) volts: 7.8
    min: 7.8 model: ASUSTeK ASUS Battery type: Li-ion serial: N/A
    status: discharging cycles: 180
  Device-1: hidpp_battery_0 model: Logitech Wireless Keyboard K230
    serial: <filter> charge: 100% (should be ignored) rechargeable: yes
    status: discharging
  Device-2: hidpp_battery_1 model: Logitech Wireless Mouse serial: <filter>
    charge: 55% (should be ignored) rechargeable: yes status: discharging
Memory:
  RAM: total: 11.55 GiB used: 6.09 GiB (52.8%)
  RAM Report:
    permissions: Unable to run dmidecode. Root privileges required.
CPU:
  Info: model: Intel Core i3-10110U bits: 64 type: MT MCP
    arch: Comet/Whiskey Lake note: check gen: core 10 built: 2018
    process: Intel 14nm family: 6 model-id: 0x8E (142) stepping: 0xC (12)
    microcode: 0xF0
  Topology: cpus: 1x cores: 2 tpc: 2 threads: 4 smt: enabled cache:
    L1: 128 KiB desc: d-2x32 KiB; i-2x32 KiB L2: 512 KiB desc: 2x256 KiB
    L3: 4 MiB desc: 1x4 MiB
  Speed (MHz): avg: 900 min/max: 400/4100 scaling: driver: intel_pstate
    governor: powersave cores: 1: 900 2: 900 3: 900 4: 900 bogomips: 20810
  Flags: 3dnowprefetch abm acpi adx aes aperfmperf apic arat
    arch_capabilities arch_perfmon art avx avx2 bmi1 bmi2 bts clflush clflushopt
    cmov constant_tsc cpuid cpuid_fault cx16 cx8 de ds_cpl dtes64 dtherm dts
    epb ept ept_ad erms est f16c flexpriority flush_l1d fma fpu fsgsbase fxsr
    ht hwp hwp_act_window hwp_epp hwp_notify ibpb ibrs ibrs_enhanced ida
    intel_pt invpcid invpcid_single lahf_lm lm mca mce md_clear mmx monitor
    movbe mpx msr mtrr nonstop_tsc nopl nx pae pat pbe pcid pclmulqdq pdcm
    pdpe1gb pebs pge pln pni popcnt pse pse36 pts rdrand rdseed rdtscp
    rep_good sdbg sep smap smep ss ssbd sse sse2 sse4_1 sse4_2 ssse3 stibp
    syscall tm tm2 tpr_shadow tsc tsc_adjust tsc_deadline_timer vme vmx vnmi
    vpid x2apic xgetbv1 xsave xsavec xsaveopt xsaves xtopology xtpr
  Vulnerabilities:
  Type: itlb_multihit status: KVM: VMX disabled
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: mmio_stale_data mitigation: Clear CPU buffers; SMT vulnerable
  Type: spec_store_bypass
    mitigation: Speculative Store Bypass disabled via prctl and seccomp
  Type: spectre_v1
    mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2 status: Vulnerable: eIBRS with unprivileged eBPF
  Type: srbds mitigation: Microcode
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: Intel CometLake-U GT2 [UHD Graphics] vendor: ASUSTeK driver: i915
    v: kernel arch: Gen9.5 process: Intel 14nm built: 2016-20 ports:
    active: HDMI-A-1 off: eDP-1 empty: none bus-ID: 00:02.0 chip-ID: 8086:9b41
    class-ID: 0300
  Device-2: IMC Networks USB2.0 HD UVC WebCam type: USB driver: uvcvideo
    bus-ID: 1-6:4 chip-ID: 13d3:56dd class-ID: 0e02 serial: <filter>
  Display: x11 server: X.Org v: 21.1.3 compositor: kwin_x11 driver: X:
    loaded: modesetting alternate: fbdev,vesa gpu: i915 display-ID: :0
    screens: 1
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.00x11.22")
    s-diag: 582mm (22.93")
  Monitor-1: HDMI-A-1 mapped: HDMI-1 pos: primary model: Dell P2419H
    serial: <filter> built: 2020 res: 1920x1080 hz: 60 dpi: 93 gamma: 1.2
    size: 527x296mm (20.75x11.65") diag: 604mm (23.8") ratio: 16:9 modes:
    max: 1920x1080 min: 720x400
  Monitor-2: eDP-1 note: disabled model: BOE Display 0x07f1 built: 2018
    res: 1920x1080 dpi: 142 gamma: 1.2 size: 344x193mm (13.54x7.6")
    diag: 394mm (15.5") ratio: 16:9 modes: 1920x1080
  OpenGL: renderer: Mesa Intel UHD Graphics (CML GT2) v: 4.6 Mesa 22.1.2
    direct render: Yes
Audio:
  Device-1: Intel Comet Lake PCH-LP cAVS vendor: ASUSTeK driver: snd_hda_intel
    v: kernel alternate: snd_soc_skl,snd_sof_pci_intel_cnl bus-ID: 00:1f.3
    chip-ID: 8086:02c8 class-ID: 0403
  Sound Server-1: ALSA v: k5.15.49-1-MANJARO running: yes
  Sound Server-2: JACK v: 1.9.21 running: no
  Sound Server-3: PulseAudio v: 16.1 running: yes
  Sound Server-4: PipeWire v: 0.3.52 running: yes
Network:
  Device-1: Intel Comet Lake PCH-LP CNVi WiFi driver: iwlwifi v: kernel
    bus-ID: 00:14.3 chip-ID: 8086:02f0 class-ID: 0280
  IF: wlo1 state: up mac: <filter>
  IP v4: <filter> type: dynamic noprefixroute scope: global
    broadcast: <filter>
  WAN IP: <filter>
Bluetooth:
  Device-1: Intel Bluetooth 9460/9560 Jefferson Peak (JfP) type: USB
    driver: btusb v: 0.8 bus-ID: 1-10:5 chip-ID: 8087:0aaa class-ID: e001
  Report: rfkill ID: hci0 rfk-id: 3 state: down bt-service: enabled,running
    rfk-block: hardware: no software: yes address: see --recommends
Logical:
  Message: No logical block device data found.
RAID:
  Hardware-1: Intel Device driver: ahci v: 3.0 port: 3060 bus-ID: 00:17.0
    chip-ID: 8086:02d7 rev: class-ID: 0104
Drives:
  Local Storage: total: 476.94 GiB used: 76.12 GiB (16.0%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Intel model: SSDPEKNW512G8
    size: 476.94 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s
    lanes: 4 type: SSD serial: <filter> rev: 004C temp: 33.9 C scheme: GPT
  Message: No optical or floppy data found.
Partition:
  ID-1: / raw-size: 467.84 GiB size: 459.43 GiB (98.20%)
    used: 76.12 GiB (16.6%) fs: ext4 dev: /dev/nvme0n1p2 maj-min: 259:2
    label: N/A uuid: 6c041c4e-e9ca-4e70-9edc-6656731e29bd
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
    used: 288 KiB (0.1%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1
    label: NO_LABEL uuid: 19F0-F078
Swap:
  Kernel: swappiness: 60 (default) cache-pressure: 100 (default)
  ID-1: swap-1 type: partition size: 8.8 GiB used: 0 KiB (0.0%) priority: -2
    dev: /dev/nvme0n1p3 maj-min: 259:3 label: swap
    uuid: 2ba2089c-de98-4caf-9c87-b60340f023ae
Unmounted:
  Message: No unmounted partitions found.
USB:
  Hub-1: 1-0:1 info: Hi-speed hub with single TT ports: 12 rev: 2.0
    speed: 480 Mb/s chip-ID: 1d6b:0002 class-ID: 0900
  Device-1: 1-1:2 info: Logitech Unifying Receiver type: Keyboard,Mouse,HID
    driver: logitech-djreceiver,usbhid interfaces: 3 rev: 2.0 speed: 12 Mb/s
    power: 98mA chip-ID: 046d:c52b class-ID: 0300
  Device-2: 1-4:3 info: Logitech Unifying Receiver type: Keyboard,Mouse,HID
    driver: logitech-djreceiver,usbhid interfaces: 3 rev: 2.0 speed: 12 Mb/s
    power: 98mA chip-ID: 046d:c52b class-ID: 0300
  Device-3: 1-6:4 info: IMC Networks USB2.0 HD UVC WebCam type: Video
    driver: uvcvideo interfaces: 2 rev: 2.0 speed: 480 Mb/s power: 500mA
    chip-ID: 13d3:56dd class-ID: 0e02 serial: <filter>
  Device-4: 1-10:5 info: Intel Bluetooth 9460/9560 Jefferson Peak (JfP)
    type: Bluetooth driver: btusb interfaces: 2 rev: 2.0 speed: 12 Mb/s
    power: 100mA chip-ID: 8087:0aaa class-ID: e001
  Hub-2: 2-0:1 info: Super-speed hub ports: 6 rev: 3.1 speed: 10 Gb/s
    chip-ID: 1d6b:0003 class-ID: 0900
Sensors:
  System Temperatures: cpu: 59.0 C pch: 48.0 C mobo: N/A
  Fan Speeds (RPM): cpu: 3100
Info:
  Processes: 280 Uptime: 1h 12m wakeups: 11 Init: systemd v: 251
  default: graphical tool: systemctl Compilers: gcc: 12.1.0 clang: 13.0.1
  Packages: 1375 pacman: 1361 lib: 367 flatpak: 7 snap: 7 Shell: Zsh v: 5.9
  running-in: konsole inxi: 3.3.19
 ļŒ’ ī‚° ļ€• ~ ī‚°                                                                                                     ī‚² āœ” 

yes youā€™re correct, im using an intel gpu

I doubt this will work (but it should be done regardless for performance and stability):

Remove the package xf86-video-intel and install the package intel-media-sdk, then reboot.

Also, can you post the contents of /etc/X11/ before you do anything else?

ls -lR /etc/X11/

After rebooting, if it still has the same issue with Firefox, there might be a particular setting in Firefox that is the culprit, even on a fresh profile.

/etc/X11/:
total 12
drwxr-xr-x 2 root root 4096 Dec 18  2021 mhwd.d
drwxr-xr-x 3 root root 4096 Apr 16 10:47 xinit
drwxr-xr-x 2 root root 4096 Apr 23 15:47 xorg.conf.d

/etc/X11/mhwd.d:
total 0

/etc/X11/xinit:
total 12
-rw-r--r-- 1 root root  739 Oct 10  2020 xinitrc
drwxr-xr-x 2 root root 4096 Jun 25 20:36 xinitrc.d
-rw-r--r-- 1 root root   45 Oct 10  2020 xserverrc

/etc/X11/xinit/xinitrc.d:
total 12
-rwxr-xr-x 1 root root 318 Apr  2 00:32 40-libcanberra-gtk-module.sh
-rwxr-xr-x 1 root root 538 Jun  8 19:28 50-systemd-user.sh
-rwxr-xr-x 1 root root 243 Jun 18 16:38 80xapp-gtk3-module.sh

/etc/X11/xorg.conf.d:
total 8
-rw-r--r-- 1 root root 232 Apr 23 15:47 00-keyboard.conf
-rw-r--r-- 1 root root 131 Apr 16 10:47 30-touchpad.conf