meta viewport minimal-ui… a good idea in it’s time, just not useable…

Apple added this capability for fullscreen browser applications in Safari for IOS 7.1, unfortunately, they removed it in IOS 8.0


<meta name="viewport" content="width=device-width, minimal-ui" />

REFERENCES:

Take and save a screenshot capture with Selenium

As I recently discussed Selenium, it might be useful to know how to take screen captures during tests. I’ve found that putting the function into a java method makes usage a LOT easier… here are the relevant code bits (obviously this will not run on it’s own). Feel free to expand on it as needed as this is just a stub.


import java.io.File;
import java.io.IOException;
import org.apache.commons.io.FileUtils;
import org.openqa.selenium.OutputType;
import org.openqa.selenium.TakesScreenshot;
import org.openqa.selenium.WebDriver;
/**
* @param driver {@code WebDriver}
* @param filename {@code String}
*/
protected static void takeScreenshot(final WebDriver driver, final String suffix){
final String fn = "takeScreenshot("+ driver.getCurrentUrl() +","+suffix+")";
final String filename = "/tmp/screenshot_" + suffix + ".png";

LOGGER.debug("takeScreenshot("+ driver.getCurrentUrl() +","+filename+")");
final File scrFile = ((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE);
// Now you can do whatever you need to do with it, for example copy somewhere
try{
FileUtils.copyFile(scrFile, new File(filename));
LOGGER.debug("[EXEC] {} {}",filename, fn);
}
catch(final IOException ex){
LOGGER.error("IOException:fn={},file={}:ex={}",fn,filename,ex);
}

}

HTML cleartype meta tag?

This tag allows for activation of ClearType in Mobile IE for smoothing fonts.


<!--[if IEMobile]><meta http-equiv="cleartype" content="on" /><![endif]-->

NOTE: Future use of this approach is questionable, as MSIE10 dropped support of conditional comments, and HTML5 validators (in general) do not “like” the http-equiv values as they are not standardized

REFERENCES:

Ubuntu fixing screen backlight brightness toggle

For quite some time, my primary Ubuntu laptop has had a problem with the keyboard keys used to adjust the screen brightness. This had been an annoyance on some of my travels where I’d wanted to extend battery life, as well as when I prefer to work in a darker space. I knew that it had to be a software driver issue of some sort, as it worked in my sometimes used dual boot Windows environment, but I’d never been bothered enough to look for a solution.

Truth is, it only took a minute or two to fix this!

  1. Modify the grub boot loader.
    sudo vi /etc/default/grub
  2. Change the line from:
    GRUB_CMDLINE_LINUX=""
    to
    GRUB_CMDLINE_LINUX="quiet splash acpi_osi=Linux acpi_backlight=vendor"
  3. Update the loader:
    sudo update-grub
  4. Reboot and you should be good to go!

REFERENCES: