]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt4/QNote.C
enable Font cache only for MacOSX and inline width() for other platform.
[lyx.git] / src / frontends / qt4 / QNote.C
index 6d49ae2f4bae67b685dd6dbd4e590537dc4e3260..af1b5ab4baddd6397f9d9c98b3ce51c99677d383 100644 (file)
@@ -31,7 +31,7 @@ typedef QController<ControlNote, QView<QNoteDialog> > base_class;
 
 
 QNote::QNote(Dialog & parent)
-       : base_class(parent, _("Note Settings"))
+       : base_class(parent, lyx::to_utf8(_("Note Settings")))
 {}
 
 
@@ -46,18 +46,9 @@ void QNote::build_dialog()
 
 void QNote::update_contents()
 {
-       // FIXME: This needs fixing. Framed and Shaded is not working.
        QRadioButton * rb = 0;
 
        switch (controller().params().type) {
-       case InsetNoteParams::Framed:
-               //rb = dialog_->framedRB;
-               rb = dialog_->greyedoutRB;
-               break;
-       case InsetNoteParams::Shaded:
-               //rb = dialog_->shadedRB;
-               rb = dialog_->greyedoutRB;
-               break;
        case InsetNoteParams::Note:
                rb = dialog_->noteRB;
                break;
@@ -67,6 +58,12 @@ void QNote::update_contents()
        case InsetNoteParams::Greyedout:
                rb = dialog_->greyedoutRB;
                break;
+       case InsetNoteParams::Framed:
+               rb = dialog_->framedRB;
+               break;
+       case InsetNoteParams::Shaded:
+               rb = dialog_->shadedRB;
+               break;
        }
 
        rb->setChecked(true);
@@ -81,6 +78,10 @@ void QNote::apply()
                type = InsetNoteParams::Greyedout;
        else if (dialog_->commentRB->isChecked())
                type = InsetNoteParams::Comment;
+       else if (dialog_->framedRB->isChecked())
+               type = InsetNoteParams::Framed;
+       else if (dialog_->shadedRB->isChecked())
+               type = InsetNoteParams::Shaded;
        else
                type = InsetNoteParams::Note;