Q:

Take screenshot element in selenium on ubuntu wrong position

When I change the environment from Windows 10 to Ubuntu and some function is not working good. Like that function take a screenshot
Please help me find the solution take a screenshot on Ubuntu. When take a screenshot on Ubuntu the picture I think is the wrong position of the element. Thank you
Working for Windows 10
 public void captureElementScreenshot(WebElement element, String fileName) {
    //Capture entire page screenshot as buffer.
    //Used TakesScreenshot, OutputType Interface of selenium and File class of java to capture screenshot of entire page.
    File screen = ((TakesScreenshot) driver).getScreenshotAs(OutputType.FILE);

    //Used selenium getSize() method to get height and width of element.
    //Retrieve width of element.
    int ImageWidth = element.getSize().getWidth();
    //Retrieve height of element.
    int ImageHeight = element.getSize().getHeight();

    //Used selenium Point class to get x y coordinates of Image element.
    //get location(x y coordinates) of the element.
    Point point = element.getLocation();
    int xcord = point.getX();
    int ycord = point.getY();

    //Reading full image screenshot.
    BufferedImage img = null;
    try {
        img = ImageIO.read(screen);
        BufferedImage dest = img.getSubimage(xcord, ycord, ImageWidth, ImageHeight);
        ImageIO.write(dest, "png", screen);

        //Used FileUtils class of apache.commons.io.
        //save Image screenshot In D: drive.
        FileUtils.copyFile(screen, new File(System.getProperty("user.dir") + "//src//test//screenshot//" + fileName + ".png"));
        System.out.println("Success save file " + fileName);
    } catch (IOException e) {
        e.printStackTrace();
    }

    //cut Image using height, width and x y coordinates parameters.

}

And this config browser 
 System.setProperty("webdriver.chrome.driver", System.getProperty("user.dir") + "//src//test//browser//chromedriver");
 DesiredCapabilities capabilities = DesiredCapabilities.chrome();
 ChromeOptions options = new ChromeOptions();
 options.addArguments("force-device-scale-factor=0.75");
 options.addArguments("high-dpi-support=0.75");
 capabilities.setCapability(ChromeOptions.CAPABILITY, options);
 driver = new ChromeDriver(capabilities);
 driver.manage().window().maximize();

A:

It's about two line code. I have commented and It's working
    options.addArguments("force-device-scale-factor=0.75");
 options.addArguments("high-dpi-support=0.75");

