From 9e159bcf9aadc7468ec46ca08a25519986b6a205 Mon Sep 17 00:00:00 2001 From: shatty Date: Sat, 7 Dec 2002 19:50:33 +0000 Subject: [PATCH] update the alignment menu based on the current alignment of the text view git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2175 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/stylededit/StyledEditWindow.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/apps/stylededit/StyledEditWindow.cpp b/src/apps/stylededit/StyledEditWindow.cpp index 953c352a4c..38dda61f5e 100644 --- a/src/apps/stylededit/StyledEditWindow.cpp +++ b/src/apps/stylededit/StyledEditWindow.cpp @@ -716,6 +716,21 @@ StyledEditWindow::MenusBeginning() } } } + + switch (fTextView->Alignment()) { + case B_ALIGN_LEFT: + fAlignLeft->SetMarked(true); + break; + case B_ALIGN_CENTER: + fAlignCenter->SetMarked(true); + break; + case B_ALIGN_RIGHT: + fAlignRight->SetMarked(true); + break; + default: + // I am so confused. + break; + } } void