Hi Demetri,
Thanks for contacting support.
I have tested the scenario using Aspose.Pdf for Java 9.5.0 where I have used the following code snippet based over new Document Object Model (DOM) of com.aspose.pdf namespace and I am afraid I am unable to notice any issue. The table is properly being aligned according to value passed in setLeft(…) method.
For your reference, I have also attached the resultant file generated over my end. Please try using the new DOM and in case you still face the same issue, please share the complete code snippet. We are sorry for this inconvenience.
com.aspose.pdf.Document doc = new com.aspose.pdf.Document();
doc.getPages().add();
//add table
com.aspose.pdf.Table table = new com.aspose.pdf.Table();
table.setColumnWidths("192 68 95");
table.getMargin().setTop(10);
table.setLeft(100f);
//draw border lines
table.setDefaultCellBorder(new com.aspose.pdf.BorderInfo(com.aspose.pdf.BorderSide.All, com.aspose.pdf.Color.getBlack()));
//cell format
com.aspose.pdf.TextFragment leftCell = new com.aspose.pdf.TextFragment("sample string");
leftCell.setHorizontalAlignment(com.aspose.pdf.TextAlignment.Center);
leftCell.getTextState().setFontStyle(com.aspose.pdf.FontStyles.Bold);
//leftCell.get setBackgroundColor(com.aspose.pdf.Color.getBeige());
leftCell.getMargin().setTop(2);
leftCell.getMargin().setBottom(2);
leftCell.getMargin().setLeft(2);
leftCell.getMargin().setRight(2);
//create row
com.aspose.pdf.Row row = new com.aspose.pdf.Row();
row.setBackgroundColor(com.aspose.pdf.Color.getPink());
//write
//row.setCells(new Cell(),"text",new TextFormat("BY2012 $M", leftCell),new TextFormat("BY2012 $M", leftCell),new TextFormat("TY $M", leftCell));
com.aspose.pdf.Cell cell = new com.aspose.pdf.Cell();
cell.getParagraphs().add(leftCell);
row.getCells().add(cell);
//row.getCells().get_Item(1).getParagraphs().add(leftCell);
//add row to table
table.getRows().add(row);
//add table to page
doc.getPages().get_Item(1).getParagraphs().add(table);
doc.save("c:/pdftest/TableAlignment.pdf");