Font too large for buttons in Mint Linux

In a browser on CentOS the text size in my buttons looks fine, but in Linux Mint Firefox the text is too large. I know how to fix this on a Linux Desktop app, but this is a Web App viewing in a Linux browser. In Linux FireFox the default font size is 16-point, but setting the default lower doesn’t solve the problem. The font size problem is the same whether the Web App itself is running on Windows, Linux or Mac, so it seems to be a Linux browser issue.

Is there a way to solve this? Do I need to reduce the text size of every button and popup menu used (via a Style) based on the OS and browser?

Consider checking if Session.Platform = WebSession.PlatformType.Linux and then increasing the size of each WebButton and WebPopupMenu with something like:

For Count_Integer As Integer = 0 To My_WebView.ControlCount - 1 Select Case My_WebView.ControlAtIndex(Count_Integer) Case IsA WebButton WebButton(My_WebView.ControlAtIndex(Count_Integer)).Top = WebButton(My_WebView.ControlAtIndex(Count_Integer)).Top - 3 WebButton(My_WebView.ControlAtIndex(Count_Integer)).Height = WebButton(My_WebView.ControlAtIndex(Count_Integer)).Height + 6 Case IsA WebPopupMenu WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Top = WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Top - 3 WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Height = WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Height + 6 End Next

It’s not ideal but does work as long as the controls are not too close to each other vertically. You could further narrow down the code execution to specific browsers on Linux by checking Session.Browser and even Session.BrowserVersion.

[quote=176671:@Frederick Roller]Consider checking if Session.Platform = WebSession.PlatformType.Linux and then increasing the size of each WebButton and WebPopupMenu with something like:

For Count_Integer As Integer = 0 To My_WebView.ControlCount - 1 Select Case My_WebView.ControlAtIndex(Count_Integer) Case IsA WebButton WebButton(My_WebView.ControlAtIndex(Count_Integer)).Top = WebButton(My_WebView.ControlAtIndex(Count_Integer)).Top - 3 WebButton(My_WebView.ControlAtIndex(Count_Integer)).Height = WebButton(My_WebView.ControlAtIndex(Count_Integer)).Height + 6 Case IsA WebPopupMenu WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Top = WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Top - 3 WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Height = WebPopupMenu(My_WebView.ControlAtIndex(Count_Integer)).Height + 6 End Next

It’s not ideal but does work as long as the controls are not too close to each other vertically. You could further narrow down the code execution to specific browsers on Linux by checking Session.Browser and even Session.BrowserVersion.[/quote]

Alternatively, he could apply a style with smaller text size.

Frederick’s code worked well and I have applied it to all my web pages, dialogs and containers, but I had to comment out the … .Top lines since they were blocking the WebButtons from locking to the bottom of the screen if the page resized.

Plus I surrounded the code with this so it wouldn’t affect other platforms:

if Session.Platform = WebSession.PlatformType.Linux then … end if