Поиск в Поддержке

Избегайте мошенников, выдающих себя за службу поддержки. Мы никогда не попросим вас позвонить, отправить текстовое сообщение или поделиться личной информацией. Сообщайте о подозрительной активности, используя функцию «Пожаловаться».

Learn More

Why does the iconised firefox window use a 256x256 bitmap? (Firefox 18.0, Centos 6.3, TWM)

  • 4 ответа
  • 1 имеет эту проблему
  • 6 просмотров
  • Последний ответ от ftww

more options

I'm using twm on a new installation of Centos6.3, with Firefox 18.0. When I iconise the Firefox window the resulting icon bitmap (as used in twm's icons) is a rather large 256x256, rather than more usual sizes around the 16 to 32 mark.

I get the same effect with a remote session where twm is running on an older FC11 box but Firefox is running on the Centos one. In contrast, with Firefox 3.5.5 on the FC11 box the icon sizes are small as expected (and desired).

Investigating with xprop, I see that the _NET_WM_ICON(CARDINAL) property is set on the newer firefox and contains an entry for the 256x256 bitmap. It /seems/ like this bitmap is compiled in as renaming /usr/share/icons/hicolor/256x256/apps/firefox.png did not change the situation, and that was the only large firefox icon that I could find in the filesystem. Is there any way to tell firefox not to provide this large bitmap as a potential icon for the window manager?


EDIT: A satisfactory workaround in my case was to use ForceIcons as explained by AndrewA below. After inspecting the TWM source I found that the window name matching could be done on the WM_CLASS data as well as the name, so simply using "Firefox" as the string to match against works. Thanks again to AndrewA.

I'm using twm on a new installation of Centos6.3, with Firefox 18.0. When I iconise the Firefox window the resulting icon bitmap (as used in twm's icons) is a rather large 256x256, rather than more usual sizes around the 16 to 32 mark. I get the same effect with a remote session where twm is running on an older FC11 box but Firefox is running on the Centos one. In contrast, with Firefox 3.5.5 on the FC11 box the icon sizes are small as expected (and desired). Investigating with xprop, I see that the _NET_WM_ICON(CARDINAL) property is set on the newer firefox and contains an entry for the 256x256 bitmap. It /seems/ like this bitmap is compiled in as renaming /usr/share/icons/hicolor/256x256/apps/firefox.png did not change the situation, and that was the only large firefox icon that I could find in the filesystem. Is there any way to tell firefox not to provide this large bitmap as a potential icon for the window manager? EDIT: A satisfactory workaround in my case was to use ForceIcons as explained by AndrewA below. After inspecting the TWM source I found that the window name matching could be done on the WM_CLASS data as well as the name, so simply using "Firefox" as the string to match against works. Thanks again to AndrewA.

Изменено ftww

Все ответы (4)

more options

I'm afraid that this isn't a particularly helpful comment, unless someone can find the answer to the next problem.

If I add the following snippet to my .twmrc file


IconDirectory "~/icons" ForceIcons Icons {

      # Firefox 17 has a 256x256+ icon ! Override it
      # This line works - when I view pages with out a <title>
      "Mozilla Firefox"      "firefox32.xbm"
      # Works for https://support.mozilla.org/en-US/questions/950850
      "Why does the iconised firefox window use a 256x256 bitmap? (Firefox 18.0, Centos 6.3, TWM) | Firefox Support Forum | Mozilla Support - Mozilla Firefox"   "firefox32.xbm"
      # These do not seem to be the wild card I had hoped for
      "*Mozilla Firefox"      "firefox32.xbm"
      ".*Mozilla Firefox"     "firefox32.xbm"

}


then I get a sensible icon (~/icon/firefox32.xbm) for web pages without a <title> tag, and for https://support.mozilla.org/en-US/questions/950850, but I haven't found a wild-card or pattern match to make it work whatever the webpage title.

more options

Thanks for your response, AndrewA. It is probably enough for me to bodge a workaround (always having a tab open with a known name and only iconising on that tab), but as you observe twm does not support wildcard matching.

I'm still bemused as to why Firefox is supplying such a large icon in the first place, though -- the whole point of icons is that they are small! -- but cannot tell if this is unreasonable of Firefox or if twm is behind the times (or both).

Thank you again!

more options

Sadly TWM is behind the times.

From http://standards.freedesktop.org/wm-spec/1.3/ar01s05.html

_NET_WM_ICON ...

The Window Manager MAY scale any of these icons to an appropriate size.

... but twm doesn't scale the icons.

I like the idea of switching to a particular tab before closing the window. The idea of

more options

Thanks again, AndrewA. After inspecting the TWM source I discovered that the matching is also done against the WM_CLASS information, so simply using "Firefox" as the string to match against works exactly as desired.