001package com.hfg.xml.msofficexml.docx;
002
003
004public class DocxUtil
005{
006   private static int PIXELS_PER_INCH = 96;
007
008   /**
009    * Converts the value to Dxa (twentieths of a point).
010    */
011   public static int convertPixelsToDxa(int inPixelValue)
012   {
013      // There are 72 points per inch.
014      float points = inPixelValue * 72 / PIXELS_PER_INCH;
015
016      return (int) (points * 5);
017   }
018}