Disable various buttons when buffer is read only

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2464 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Angus Leeming 2001-08-09 15:10:24 +00:00
parent 4e4ebe5d4d
commit 06c830f488
6 changed files with 37 additions and 7 deletions

View File

@ -1,3 +1,15 @@
2001-08-09 Angus Leeming <a.leeming@ic.ac.uk>
* FormCitation.C (build):
* FormDocument.C (build):
* FormMinipage.C (build):
* FormParagraph.C (build):
* FormRef.C (build): added stuff to read-only list in the
button controller.
* FormCitation.C (update): disable citation style stuff when not using
Natbib.
2001-08-06 Juergen Vigna <jug@sad.it>
* forms/form_ert.fd: new file.

View File

@ -153,6 +153,8 @@ void FormCitation::build()
bc().addReadOnly(dialog_->choice_style);
bc().addReadOnly(dialog_->input_before);
bc().addReadOnly(dialog_->input_after);
bc().addReadOnly(dialog_->button_full_author_list);
bc().addReadOnly(dialog_->button_force_uppercase);
}
@ -385,6 +387,11 @@ void FormCitation::update()
dialog_->button_full_author_list,
dialog_->button_force_uppercase,
controller().params().getCmdName());
bool const natbib = controller().usingNatbib();
setEnabled(dialog_->button_full_author_list, natbib);
setEnabled(dialog_->button_force_uppercase, natbib);
setEnabled(dialog_->choice_style, natbib);
// No keys have been selected yet, so...
fl_clear_browser(dialog_->browser_info);

View File

@ -201,6 +201,9 @@ void FormDocument::build()
" «text» | »text« "));
bc().addReadOnly (language_->choice_inputenc);
bc().addReadOnly (language_->choice_quotes_language);
bc().addReadOnly (language_->radio_single);
bc().addReadOnly (language_->radio_double);
// the document options form
options_.reset(build_doc_options());
@ -237,6 +240,8 @@ void FormDocument::build()
bc().addReadOnly (bullets_->bmtable_bullet_panel);
bc().addReadOnly (bullets_->choice_bullet_size);
bc().addReadOnly (bullets_->input_bullet_latex);
bc().addReadOnly (bullets_->radio_bullet_depth);
bc().addReadOnly (bullets_->radio_bullet_panel);
fl_addto_tabfolder(dialog_->tabbed_folder,_("Document"),
class_->form);

View File

@ -49,9 +49,10 @@ void FormMinipage::build()
bc().addReadOnly(dialog_->input_width);
bc().addReadOnly(dialog_->choice_width_units);
bc().addReadOnly(dialog_->radio_top);
bc().addReadOnly(dialog_->radio_middle);
bc().addReadOnly(dialog_->radio_bottom);
bc().addReadOnly(dialog_->group_alignment);
// bc().addReadOnly(dialog_->radio_top);
// bc().addReadOnly(dialog_->radio_middle);
// bc().addReadOnly(dialog_->radio_bottom);
}

View File

@ -127,10 +127,11 @@ void FormParagraph::build()
fl_set_input_return(general_->input_space_below, FL_RETURN_CHANGED);
fl_set_input_return(general_->input_labelwidth, FL_RETURN_CHANGED);
bc_.addReadOnly (general_->radio_align_right);
bc_.addReadOnly (general_->radio_align_left);
bc_.addReadOnly (general_->radio_align_block);
bc_.addReadOnly (general_->radio_align_center);
bc_.addReadOnly (general_->group_radio_alignment);
// bc_.addReadOnly (general_->radio_align_right);
// bc_.addReadOnly (general_->radio_align_left);
// bc_.addReadOnly (general_->radio_align_block);
// bc_.addReadOnly (general_->radio_align_center);
bc_.addReadOnly (general_->check_lines_top);
bc_.addReadOnly (general_->check_lines_bottom);
bc_.addReadOnly (general_->check_pagebreaks_top);

View File

@ -54,6 +54,10 @@ void FormRef::build()
bc().setApply(dialog_->button_apply);
bc().setCancel(dialog_->button_cancel);
bc().setRestore(dialog_->button_restore);
bc().addReadOnly(dialog_->button_update);
bc().addReadOnly(dialog_->name);
bc().addReadOnly(dialog_->ref);
}