TableRow row = new TableRow(this);
TextView label = new TextView(this);
label.setText(R.string.table_layout_7_quit);
label.setPadding(3, 3, 3, 3);
TextView shortcut = new TextView(this);
shortcut.setText(R.string.table_layout_7_ctrlq);
shortcut.setPadding(3, 3, 3, 3);
shortcut.setGravity(Gravity.RIGHT | Gravity.TOP);
row.addView(label, new TableRow.LayoutParams(1));
row.addView(shortcut, new TableRow.LayoutParams());
table.addView(row, new TableLayout.LayoutParams());