Merge branch 'Release_2_8_2_Branch' into JAL-429_phylip-file-support
authorJim Procter <j.procter@dundee.ac.uk>
Mon, 6 Oct 2014 15:33:17 +0000 (16:33 +0100)
committerJim Procter <j.procter@dundee.ac.uk>
Mon, 6 Oct 2014 15:33:17 +0000 (16:33 +0100)
Conflicts:
src/jalview/io/AppletFormatAdapter.java

183 files changed:
resources/lang/Messages.properties
resources/lang/Messages_es.properties
src/MCview/PDBViewer.java
src/MCview/PDBfile.java
src/com/stevesoft/pat/Pattern.java
src/com/stevesoft/pat/Regex.java
src/com/stevesoft/pat/Replacer.java
src/com/stevesoft/pat/Transformer.java
src/com/stevesoft/pat/wrap/RandomAccessFileWrap.java
src/ext/vamsas/IRegistryServiceLocator.java
src/ext/vamsas/JpredServiceLocator.java
src/ext/vamsas/MuscleWSServiceLocator.java
src/ext/vamsas/SeqSearchServiceLocator.java
src/jalview/analysis/AlignSeq.java
src/jalview/analysis/AlignmentSorter.java
src/jalview/analysis/Rna.java
src/jalview/appletgui/APopupMenu.java
src/jalview/appletgui/AlignFrame.java
src/jalview/appletgui/AnnotationColourChooser.java
src/jalview/appletgui/AppletJmol.java
src/jalview/appletgui/EmbmenuFrame.java
src/jalview/appletgui/FeatureRenderer.java
src/jalview/appletgui/FeatureSettings.java
src/jalview/appletgui/RedundancyPanel.java
src/jalview/appletgui/SeqPanel.java
src/jalview/appletgui/SliderPanel.java
src/jalview/appletgui/UserDefinedColours.java
src/jalview/bin/Jalview.java
src/jalview/bin/JalviewLite.java
src/jalview/binding/Annotation.java
src/jalview/binding/FeatureSettings.java
src/jalview/binding/JGroup.java
src/jalview/binding/JSeq.java
src/jalview/binding/JalviewModelSequence.java
src/jalview/binding/JalviewUserColours.java
src/jalview/binding/Pdbentry.java
src/jalview/binding/PdbentryItem.java
src/jalview/binding/SequenceSet.java
src/jalview/binding/VAMSAS.java
src/jalview/controller/AlignViewController.java
src/jalview/datamodel/Alignment.java
src/jalview/datamodel/AlignmentOrder.java
src/jalview/datamodel/AlignmentView.java
src/jalview/datamodel/CigarBase.java
src/jalview/datamodel/SeqCigar.java
src/jalview/datamodel/Sequence.java
src/jalview/datamodel/SequenceI.java
src/jalview/ext/jmol/JalviewJmolBinding.java
src/jalview/ext/jmol/PDBFileWithJmol.java
src/jalview/ext/paradise/Annotate3D.java
src/jalview/ext/rbvi/chimera/JalviewChimeraBinding.java
src/jalview/gui/AlignFrame.java
src/jalview/gui/AlignmentPanel.java
src/jalview/gui/AnnotationColourChooser.java
src/jalview/gui/AnnotationExporter.java
src/jalview/gui/AnnotationLabels.java
src/jalview/gui/AnnotationPanel.java
src/jalview/gui/AppJmol.java
src/jalview/gui/BlogReader.java
src/jalview/gui/ChimeraViewFrame.java
src/jalview/gui/Console.java
src/jalview/gui/CutAndPasteHtmlTransfer.java
src/jalview/gui/CutAndPasteTransfer.java
src/jalview/gui/DasSourceBrowser.java
src/jalview/gui/Desktop.java
src/jalview/gui/FeatureRenderer.java
src/jalview/gui/FeatureSettings.java
src/jalview/gui/FontChooser.java
src/jalview/gui/IdPanel.java
src/jalview/gui/JDatabaseTree.java
src/jalview/gui/Jalview2XML.java
src/jalview/gui/Jalview2XML_V1.java
src/jalview/gui/JvSwingUtils.java
src/jalview/gui/OOMWarning.java
src/jalview/gui/OptsAndParamsPage.java
src/jalview/gui/PCAPanel.java
src/jalview/gui/Preferences.java
src/jalview/gui/RedundancyPanel.java
src/jalview/gui/SeqPanel.java
src/jalview/gui/SequenceFetcher.java
src/jalview/gui/SliderPanel.java
src/jalview/gui/TextColourChooser.java
src/jalview/gui/TreeCanvas.java
src/jalview/gui/TreePanel.java
src/jalview/gui/UserDefinedColours.java
src/jalview/gui/VamsasApplication.java
src/jalview/gui/WebserviceInfo.java
src/jalview/gui/WsJobParameters.java
src/jalview/gui/WsParamSetManager.java
src/jalview/gui/WsPreferences.java
src/jalview/io/AlignFile.java
src/jalview/io/AppletFormatAdapter.java
src/jalview/io/FileLoader.java
src/jalview/io/FileParse.java
src/jalview/io/HTMLOutput.java
src/jalview/io/JPredFile.java
src/jalview/io/JalviewFileChooser.java
src/jalview/io/JnetAnnotationMaker.java
src/jalview/io/NewickFile.java
src/jalview/io/PfamFile.java
src/jalview/io/RnamlFile.java
src/jalview/io/StockholmFile.java
src/jalview/io/VamsasAppDatastore.java
src/jalview/io/WSWUBlastClient.java
src/jalview/io/vamsas/DatastoreItem.java
src/jalview/io/vamsas/Rangetype.java
src/jalview/jbgui/GAlignFrame.java
src/jalview/jbgui/GPreferences.java
src/jalview/jbgui/GRestServiceEditorPane.java
src/jalview/jbgui/GSequenceLink.java
src/jalview/math/Matrix.java
src/jalview/schemabinding/version2/AlcodonFrame.java
src/jalview/schemabinding/version2/Annotation.java
src/jalview/schemabinding/version2/Feature.java
src/jalview/schemabinding/version2/FeatureSettings.java
src/jalview/schemabinding/version2/JGroup.java
src/jalview/schemabinding/version2/JSeq.java
src/jalview/schemabinding/version2/JalviewModelSequence.java
src/jalview/schemabinding/version2/JalviewUserColours.java
src/jalview/schemabinding/version2/MapListType.java
src/jalview/schemabinding/version2/Pdbentry.java
src/jalview/schemabinding/version2/PdbentryItem.java
src/jalview/schemabinding/version2/Pdbids.java
src/jalview/schemabinding/version2/Sequence.java
src/jalview/schemabinding/version2/SequenceSet.java
src/jalview/schemabinding/version2/VAMSAS.java
src/jalview/schemabinding/version2/Viewport.java
src/jalview/schemabinding/version2/WebServiceParameterSet.java
src/jalview/schemes/ResidueColourScheme.java
src/jalview/structure/StructureSelectionManager.java
src/jalview/util/AWTConsole.java
src/jalview/util/BrowserLauncher.java
src/jalview/util/DBRefUtils.java
src/jalview/util/GroupUrlLink.java
src/jalview/ws/AWSThread.java
src/jalview/ws/DBRefFetcher.java
src/jalview/ws/DasSequenceFeatureFetcher.java
src/jalview/ws/EnfinEnvision2OneWay.java
src/jalview/ws/dbsources/EmblXmlSource.java
src/jalview/ws/dbsources/Pdb.java
src/jalview/ws/dbsources/das/datamodel/DasSequenceSource.java
src/jalview/ws/dbsources/das/datamodel/JalviewSource.java
src/jalview/ws/ebi/EBIFetchClient.java
src/jalview/ws/jws1/Annotate3D.java
src/jalview/ws/jws1/Discoverer.java
src/jalview/ws/jws1/JPredClient.java
src/jalview/ws/jws1/JPredThread.java
src/jalview/ws/jws1/MsaWSClient.java
src/jalview/ws/jws1/MsaWSThread.java
src/jalview/ws/jws1/SeqSearchWSClient.java
src/jalview/ws/jws1/SeqSearchWSThread.java
src/jalview/ws/jws1/WS1Client.java
src/jalview/ws/jws2/JabaParamStore.java
src/jalview/ws/jws2/JabaPreset.java
src/jalview/ws/jws2/JabawsCalcWorker.java
src/jalview/ws/jws2/JabawsMsaInterfaceAlignCalcWorker.java
src/jalview/ws/jws2/Jws2Client.java
src/jalview/ws/jws2/Jws2Discoverer.java
src/jalview/ws/jws2/MsaWSClient.java
src/jalview/ws/jws2/MsaWSThread.java
src/jalview/ws/jws2/ParameterUtils.java
src/jalview/ws/jws2/SequenceAnnotationWSClient.java
src/jalview/ws/jws2/dm/AAConSettings.java
src/jalview/ws/jws2/dm/JabaOption.java
src/jalview/ws/jws2/dm/JabaValueConstrain.java
src/jalview/ws/jws2/dm/JabaWsParamSet.java
src/jalview/ws/jws2/jabaws2/Jws2Instance.java
src/jalview/ws/rest/HttpResultSet.java
src/jalview/ws/rest/RestClient.java
src/jalview/ws/rest/RestJobThread.java
src/jalview/ws/rest/params/JobConstant.java
src/jalview/ws/rest/params/SeqGroupIndexVector.java
src/jalview/ws/rest/params/Tree.java
src/jalview/ws/seqfetcher/ASequenceFetcher.java
src/org/jibble/epsgraphics/EpsDocument.java
src/org/jibble/epsgraphics/EpsGraphics2D.java
src/uk/ac/ebi/www/WSWUBlastServiceLocator.java
src/uk/ac/ebi/www/picr/AccessionMappingService/AccessionMapperServiceLocator.java
test/jalview/ext/jmol/PDBFileWithJmolTest.java
test/jalview/io/test_gz_fasta_notgz.gz [new file with mode: 0644]
test/jalview/ws/PDBSequenceFetcherTest.java
test/jalview/ws/gui/Jws2ParamView.java
test/jalview/ws/jabaws/MinJabawsClientTests.java [new file with mode: 0644]

index 6736791..cdbe0f3 100644 (file)
@@ -58,7 +58,7 @@ action.by_id = by Id
 action.by_length = by Length\r
 action.by_group = by Group\r
 action.remove = Remove\r
-action.remove_redundancy = Remove Redundancy...\r
+action.remove_redundancy = Remove Redundancy\r
 action.pairwise_alignment = Pairwise Alignments...\r
 action.by_rna_helixes = by RNA Helices\r
 action.user_defined = User Defined...\r
@@ -128,11 +128,10 @@ action.deselect_all = Deselect all
 action.invert_selection = Invert selection\r
 action.using_jmol = Using Jmol\r
 action.link = Link\r
-action.group_link = Group Links\r
+action.group_link = Group Link\r
 action.show_chain = Show Chain\r
 action.show_group = Show Group\r
 action.fetch_db_references = Fetch DB References\r
-action.edit = Edit\r
 action.view_flanking_regions = Show flanking regions\r
 label.view_flanking_regions = Show sequence data either side of the subsequences involved in this alignment\r
 label.str = Str:\r
@@ -309,7 +308,7 @@ label.to_file = to File
 label.to_textbox = to Textbox\r
 label.jalview = Jalview\r
 label.csv_spreadsheet = CSV (Spreadsheet)\r
-label.status =  [Status]\r
+label.status = Status\r
 label.channels = Channels\r
 label.channel_title_item_count = {0} ({1})\r
 label.blog_item_published_on_date = {0} {1} \r
@@ -366,7 +365,7 @@ label.enter_label = Enter label
 label.enter_label_for_the_structure = Enter a label for the structure?\r
 label.pdb_entry_is_already_displayed = {0} is already displayed.\nDo you want to re-use this viewer ?\r
 label.map_sequences_to_visible_window = Map Sequences to Visible Window: {0}\r
-label.add_pdbentry_to_view = Do you want to add {0} to the view called\n'{1}'\n\r
+label.add_pdbentry_to_view = Do you want to add {0} to the view called\n{1}\n\r
 label.align_to_existing_structure_view = Align to existing structure view\r
 label.pdb_entries_couldnt_be_retrieved = The following pdb entries could not be retrieved from the PDB\:\n{0}\nPlease try downloading them manually.\r
 label.couldnt_load_file = Couldn't load file\r
@@ -379,7 +378,7 @@ label.you_can_only_edit_or_remove_local_das_sources = You can only edit or remov
 label.public_das_source = Public DAS source - not editable\r
 label.input_alignment_from_url = Input Alignment From URL\r
 label.input_alignment = Input Alignment\r
-label.couldnt_import_as_vamsas_session = Couldn't import '{0}' as a new vamsas session.\r
+label.couldnt_import_as_vamsas_session = Couldn't import {0} as a new vamsas session.\r
 label.vamsas_document_import_failed = Vamsas Document Import Failed\r
 label.couldnt_locate = Couldn't locate {0}\r
 label.url_not_found = URL not found\r
@@ -456,8 +455,8 @@ label.settings_for_type = Settings for {0}
 label.view_full_application = View in Full Application\r
 label.load_associated_tree = Load Associated Tree ...\r
 label.load_features_annotations = Load Features/Annotations ...\r
-label.export_features = Export Features ...\r
-label.export_annotations = Export Annotations ...\r
+label.export_features = Export Features\r
+label.export_annotations = Export Annotations\r
 label.jalview_copy = Copy (Jalview Only)\r
 label.jalview_cut = Cut (Jalview Only)\r
 label.to_upper_case = To Upper Case\r
@@ -496,7 +495,7 @@ label.select_colour_maximum_value = Select Colour for Maximum Value
 label.open_new_jmol_view_with_all_structures_associated_current_selection_superimpose_using_alignment = Open a new Jmol view with all structures associated with the current selection and superimpose them using the alignment.\r
 label.open_url_param = Open URL {0}\r
 label.open_url_seqs_param = Open URL ({0}..) ({1} seqs)\r
-label.load_pdb_file_associate_with_sequence = Load a PDB file and associate it with sequence '{0}'\r
+label.load_pdb_file_associate_with_sequence = Load a PDB file and associate it with sequence {0}\r
 label.reveal_hidden_columns = Reveal Hidden Columns with Right Mouse Button\r
 label.dark_colour = Dark Colour\r
 label.light_colour = Light Colour\r
@@ -532,6 +531,7 @@ label.collect_garbage = Collect Garbage
 label.show_memory_usage = Show Memory Usage\r
 label.show_java_console = Show Java Console\r
 label.show_jalview_news = Show Jalview News\r
+label.take_snapshot = Take snapshot\r
 label.monospaced_fonts_faster_to_render = Monospaced fonts are faster to render\r
 label.anti_alias_fonts = Anti-alias Fonts (Slower to render)\r
 label.monospaced_font= Monospaced\r
@@ -728,13 +728,399 @@ label.invalid_font = Invalid Font
 label.separate_multiple_accession_ids = Separate multiple accession ids with semi colon ";"\r
 label.replace_commas_semicolons = Replace commas with semi-colons\r
 label.parsing_failed_syntax_errors_shown_below_param = Parsing failed. Syntax errors shown below {0}\r
-label.parsing_failed_unrecoverable_exception_thrown_param = \nParsing failed. An unrecoverable exception was thrown:\n {0}\r
+label.parsing_failed_unrecoverable_exception_thrown_param = \nParsing failed. An unrecoverable exception was thrown\:\n {0}\r
 label.example_query_param = Example query: {0}\r
 label.enter_value_increase_conservation_visibility = Enter value to increase conservation visibility\r
 label.enter_percentage_identity_above_which_colour_residues = Enter % identity above which to colour residues\r
-label.wswublast_client_credits = To display sequence features an exact Uniprot id with 100% sequence identity match must be entered.\nIn order to display these features, try changing the names of your sequences to the ids suggested below.\n\nRunning WSWUBlast at EBI.\nPlease quote Pillai S., Silventoinen V., Kallio K., Senger M., Sobhany S., Tate J., Velankar S., Golovin A., Henrick K., Rice P., Stoehr P., Lopez R.\nSOAP-based services provided by the European Bioinformatics Institute.\nNucleic Acids Res. 33(1):W25-W28 (2005));\r
+label.wswublast_client_credits = To display sequence features an exact Uniprot id with 100% sequence identity match must be entered.\nIn order to display these features, try changing the names of your sequences to the ids suggested below.\n\nRunning WSWUBlast at EBI.\nPlease quote Pillai S., Silventoinen V., Kallio K., Senger M., Sobhany S., Tate J., Velankar S., Golovin A., Henrick K., Rice P., Stoehr P., Lopez R.\nSOAP-based services provided by the European Bioinformatics Institute.\nNucleic Acids Res. 33(1)\:W25-W28 (2005));\r
 label.blasting_for_unidentified_sequence = BLASTing for unidentified sequences
 label.select_columns_containing = Select columns containing\r
 label.select_columns_not_containing = Select columns that do not contain\r
 option.trim_retrieved_seqs = Trim retrieved sequences\r
 label.trim_retrieved_sequences = When the reference sequence is longer than the sequence that you are working with, only keep the relevant subsequences.\r
+label.use_sequence_id_1 = Use $SEQUENCE_ID$ or $SEQUENCE_ID=/<regex>/=$\r
+label.use_sequence_id_2 = \nto embed sequence id in URL\r
+label.ws_parameters_for = Parameters for {0}\r
+label.switch_server = Switch server\r
+label.open_jabaws_web_page = Opens the JABAWS server's homepage in web browser\r
+label.choose_jabaws_server = Choose a server for running this service\r
+label.services_at = Services at {0}\r
+label.rest_client_submit = {0} using {1}\r
+label.fetch_retrieve_from =Retrieve from {0}</html>\r
+label.fetch_retrieve_from_all_sources = Retrieve from all {0} sources in {1}<br>First is :{2}<html> \r
+label.feature_settings_click_drag = <html>Click/drag feature types up or down to change render order.<br/>Double click to select columns containing feature in alignment/current selection<br/>Pressing Alt will select columns outside features rather than inside<br/>Pressing Shift to modify current selection (rather than clear current selection)<br/>Press CTRL or Command/Meta to toggle columns in/outside features<br/></html>\r
+label.opt_and_params_further_details = see further details by right-clicking\r
+label.opt_and_params_show_brief_desc_image_link = <html>Click to show brief description<br><img src="{0}"/> Right click for further information.</html> \r
+label.opt_and_params_show_brief_desc = <html>Click to show brief description<br></html>\r
+label.adjusts_width_generated_eps_png = <html>Adjusts the width of the generated EPS or PNG file to ensure even the longest sequence ID or annotation label is displayed</html>\r
+label.manually_specify_width_left_column = <html>Manually specify the width of the left hand column where sequence IDs and annotation labels will be rendered in exported alignment figures. This setting will be ignored if 'Automatically set ID width' is set</html>\r
+label.job_created_when_checked = <html>When checked, a job is created for every sequence in the current selection.</html>\r
+label.when_checked_job_visible_region_and_results = <html>When checked, a single job is created for the visible region and results mapped back onto their location in the alignment. Otherwise, a job would be created for every contiguous region visible in the alignment or current selection (e.g. a multiple alignment).</html>\r
+label.flat_file_representation = <html>Flat file representation of this rest service using the Really Simple Bioinformatics Service formalism</html>\r
+label.result_of_parsing_rsbs = <html>Results of parsing the RSBS representation</html>\r
+label.user_preset = User Preset\r
+label.service_preset = Service Preset\r
+label.run_with_preset = Run {0} with preset\r
+label.view_service_doc_url = <html>View <a href="{0}">{1}</a></html>\r
+label.submit_sequence = <html>Submit {0} {1} {2} {3} to<br/>{4}</html>\r
+action.by_title_param = by {0}\r
+label.alignment = Alignment\r
+label.secondary_structure_prediction = Secondary Structure Prediction\r
+label.sequence_database_search = Sequence Database Search\r
+label.analysis = Analysis\r
+label.protein_disorder = Protein Disorder \r
+label.source_from_db_source = Sources from {0}\r
+label.from_msname = from {0}\r
+label.superpose_with = Superpose with ...\r
+action.do = Do\r
+label.scale_label_to_column = Scale Label to Column\r
+label.add_new_row = Add New Row\r
+label.edit_label_description = Edit Label/Description\r
+label.hide_row = Hide This Row\r
+label.delete_row = Delete This Row\r
+label.show_all_hidden_rows = Show All Hidden Rows\r
+label.export_annotation = Export Annotation\r
+label.copy_consensus_sequence = Copy Consensus Sequence\r
+label.helix = Helix\r
+label.sheet = Sheet\r
+label.rna_helix = RNA Helix\r
+label.remove_annotation = Remove Annotation\r
+label.colour_by = Colour by...\r
+label.muscle_multiple_protein_sequence_alignment = Muscle Multiple Protein Sequence Alignment\r
+label.mafft_multiple_sequence_alignment = MAFFT Multiple Sequence Alignment\r
+label.clustalw_multiple_sequence_alignment = ClustalW Multiple Sequence Alignment\r
+label.jnet_secondary_structure_prediction = JNet Secondary Structure Prediction\r
+label.multiharmony = Multi-Harmony\r
+label.unable_start_web_service_analysis = Unable to start web service analysis\r
+label.job_couldnt_be_started_check_input = The Job couldn't be started. Please check your input, and the Jalview console for any warning messages.\r
+label.prompt_each_time = Prompt each time\r
+label.use_source = Use Source\r
+label.couldnt_save_project = Couldn't save project\r
+label.error_whilst_saving_current_state_to = Error whilst saving current state to {0}\r
+label.error_whilst_loading_project_from = Error whilst loading project from {0}\r
+label.couldnt_load_project = Couldn't load project\r
+label.pca_sequences_not_aligned = The sequences must be aligned before calculating PCA.\nTry using the Pad function in the edit menu,\nor one of the multiple sequence alignment web services.\r
+label.invalid_name_preset_exists = Invalid name - preset already exists.\r
+label.invalid_name = Invalid name\r
+label.set_proxy_settings = Please set up your proxy settings in the 'Connections' tab of the Preferences window\r
+label.proxy_authorization_failed = Proxy Authorization Failed\r
+label.internal_jalview_error = Internal Jalview Error\r
+label.secondary_structure_prediction_service_couldnt_be_located = The Secondary Structure Prediction Service named {0} at {1} couldn't be located.\r
+label.service_called_is_not_msa_service = The Service called \n{0}\nis not a \nMultiple Sequence Alignment Service\!\r
+label.msa_service_is_unknown = The Multiple Sequence Alignment Service named {0} is unknown\r
+label.service_called_is_not_seq_search_service = The Service called \n{0}\nis not a \nSequence Search Service\!\r
+label.seq_search_service_is_unknown = The Sequence Search Service named {0} is unknown\r
+label.feature_type = Feature Type\r
+label.display = Display\r
+label.service_url = Service URL\r
+label.copied_sequences = Copied sequences\r
+label.cut_sequences = Cut Sequences\r
+label.conservation_colour_increment = Conservation Colour Increment ({0})\r
+label.percentage_identity_thereshold = Percentage Identity Thereshold ({0})\r
+label.error_unsupported_owwner_user_colour_scheme = Unsupported owner for User Colour scheme dialog\r
+label.save_alignment_to_file = Save Alignment to file\r
+label.save_features_to_file = Save Features to File\r
+label.save_annotation_to_file = Save Annotation to File\r
+label.no_features_on_alignment = No features found on alignment\r
+label.save_pdb_file = Save PDB File\r
+label.save_text_to_file = Save Text to File\r
+label.save_state = Save State\r
+label.restore_state = Restore State\r
+label.saving_jalview_project = Saving jalview project {0}\r
+label.loading_jalview_project = Loading jalview project {0}\r
+label.save_vamsas_document_archive = Save Vamsas Document Archive\r
+label.saving_vamsas_doc = Saving VAMSAS Document to {0}\r
+label.load_feature_colours = Load Feature Colours\r
+label.save_feature_colours = Save Feature Colour Scheme\r
+label.dataset_for = {0} Dataset for {1}\r
+label.select_startup_file = Select startup file\r
+label.select_default_browser = Select default web browser\r
+label.save_tree_as_newick = Save tree as newick file\r
+label.create_eps_from_tree = Create EPS file from tree\r
+label.create_png_from_tree = Create PNG image from tree\r
+label.save_colour_scheme = Save colour scheme\r
+label.edit_params_for = Edit parameters for {0}\r
+label.choose_filename_for_param_file = Choose a filename for this parameter file\r
+label.save_as_html = Save as HTML\r
+label.recently_opened = Recently Opened\r
+label.blasting_for_unidentified_sequence_jobs_running = BLASTing for unidentified sequences - {0}  jobs running.\r
+label.tree_from = Tree from {0}\r
+label.webservice_job_title = {0} using {1}\r
+label.select_visible_region_of = selected {0} region of {1}\r
+label.visible = Visible\r
+label.select_unselect_visible_regions_from = select and unselected {0} regions from {1}\r
+label.visible_region_of = visible region of\r
+label.webservice_job_title_on = {0} using {1} on {2}\r
+label.updating_vamsas_session = Updating vamsas session\r
+label.loading_file = Loading File: {0}\r
+label.edit_params = Edit {0}\r
+error.not_implemented = Not implemented\r
+error.no_such_method_as_clone1_for = No such method as clone1 for {0}\r
+error.null_from_clone1 = Null from clone1!\r
+error.implementation_error_sortbyfeature = Implementation Error - sortByFeature method must be one of FEATURE_SCORE, FEATURE_LABEL or FEATURE_DENSITY.\r
+error.not_yet_implemented = Not yet implemented\r
+error.unknown_type_dna_or_pep = Unknown Type {0} - dna or pep are the only allowed values.\r
+error.implementation_error_dont_know_thereshold_annotationcolourgradient = Implementation error: don't know about threshold setting for current AnnotationColourGradient.\r
+error.implementation_error_embeddedpopup_not_null = Implementation error - embeddedPopup must be non-null\r
+error.invalid_colour_for_mycheckbox = Invalid color for MyCheckBox\r
+error.implementation_error_unrecognised_render_object_for_features_type = Implementation Error: Unrecognised render object {0} for features of type {1}\r
+error.implementation_error_unsupported_feature_colour_object = Implementation error: Unsupported feature colour object.\r
+error.invalid_separator_parameter = Invalid separator parameter - must be non-zero length\r
+error.alignment_cigararray_not_implemented = Alignment(CigarArray) not yet implemented\r
+error.weak_sequencei_equivalence_not_yet_implemented = Weak sequenceI equivalence not yet implemented.\r
+error.implementation_error_can_only_make_alignmnet_from_cigararray = Implementation Error - can only make an alignment view from a CigarArray of sequences.\r
+error.empty_view_cannot_be_updated = empty view cannot be updated.\r
+error.mismatch_between_number_of_sequences_in_block = Mismatch between number of sequences in block {0} ({1}) and the original view ({2})\r
+error.padding_not_yet_implemented = Padding not yet implemented\r
+error.mismatch_between_visible_blocks_to_update_and_number_of_contigs_in_view = Mismatch between visible blocks to update and number of contigs in view (contigs=0,blocks={0})\r
+error.unknown_seq_cigar_operation = Unknown SeqCigar operation {0}\r
+error.implementation_bug_parse_cigar_string = Implementation bug in parseCigarString\r
+error.implementation_error_invalid_operation_string = Implementation error. Invalid operation string.\r
+error.invalid_range_string = Invalid range string (must be zero or positive number)\r
+error.implementation_error_delete_range_out_of_bounds = Implementation Error: deleteRange out of bounds: start must be non-negative and less than end.\r
+error.implementation_error = Implementation error\r
+error.implementation_error_unknown_operation = Implementation Error! Unknown operation {0}\r
+error.implementation_error_unexpected_null_from_get_sequence_and_deletions = Implementation Error - unexpected null from getSequenceAndDeletions\r
+error.implementation_error_set_seq_null = Implementation Error - _setSeq(null,...)\r
+error.implementation_error_s = Implementation Error: _s= {0}\r
+error.implementation_error_seqcigar_possible = SeqCigar: Possible implementation error: sequence is longer than dataset sequence\r
+error.implmentation_bug_seq_null = Implementation Bug. Null seq\r
+error.implementation_bug_cigar_operation_list_range_list = Implementation Bug. Cigar Operation list!= range list\r
+error.not_yet_implemented_cigar_object_from_cigar_string = NOT YET Implemented: Constructing a Cigar object from a cigar string and a gapped sequence.\r
+error.implementation_bug_cigar_operation = Implementation Bug. Cigar Operation {0} {1} not one of {2}, {3}, or {4}.\r
+error.implementation_error_for_new_cigar = Implementation error for new Cigar(SequenceI)\r
+error.implementation_error_cigar_seq_no_operations = Implementation error: {0}th sequence Cigar has no operations.\r
+error.implementation_error_jmol_getting_data = Implementation error - Jmol seems to be still working on getting its data - report at http://issues.jalview.org/browse/JAL-1016\r
+error.implementation_error_no_pdbentry_from_index = Implementation error - no corresponding pdbentry (for index {0}) to add sequences mappings to\r
+error.jmol_version_not_compatible_with_jalview_version = Jmol version {0} is not compatible with this version of Jalview. Report this problem at issues.jalview.org\r
+error.not_implemented_remove = Remove: Not implemented\r
+error.not_implemented_clone = Clone: Not implemented\r
+error.implementation_error_chimera_getting_data = Implementation error - Chimera seems to be still working on getting its data - report at http://issues.jalview.org/browse/JAL-1016\r
+error.call_setprogressbar_before_registering_handler = call setProgressBar before registering the progress bar's handler.\r
+label.cancelled_params = Cancelled {0}\r
+error.implementation_error_cannot_show_view_alignment_frame = Implementation error: cannot show a view from another alignment in an AlignFrame.\r
+error.implementation_error_dont_know_about_thereshold_setting = Implementation error: don't know about threshold setting for current AnnotationColourGradient.\r
+error.eps_generation_not_implemented = EPS Generation not yet implemented\r
+error.png_generation_not_implemented = PNG Generation not yet implemented\r
+error.try_join_vamsas_session_another = Trying to join a vamsas session when another is already connected\r
+error.invalid_vamsas_session_id = Invalid vamsas session id\r
+error.implementation_error_cannot_create_groovyshell = Implementation Error. Cannot create groovyShell without Groovy on the classpath!\r
+label.groovy_support_failed = Jalview Groovy Support Failed\r
+label.couldnt_create_groovy_shell = Couldn't create the groovy Shell. Check the error log for the details of what went wrong.\r
+error.unsupported_version_calcIdparam = Unsupported Version for calcIdparam {0}\r
+error.implementation_error_cant_reorder_tree = Implementation Error: Can't reorder this tree. Not DefaultMutableTreeNode.\r
+error.invalid_value_for_option = Invalid value {0} for option {1}\r
+error.implementation_error_cannot_import_vamsas_doc = Implementation Error - cannot import existing vamsas document into an existing session, Yet!\r
+label.vamsas_doc_couldnt_be_opened_as_new_session = VAMSAS Document could not be opened as a new session - please choose another\r
+error.implementation_error_vamsas_operation_not_init = Impementation error! Vamsas Operations when client not initialised and connected\r
+error.jalview_no_connected_vamsas_session = Jalview not connected to Vamsas session\r
+error.implementation_error_cannot_recover_vamsas_object_mappings = IMPLEMENTATION ERROR: Cannot recover vamsas object mappings - no backup was made\r
+error.setstatus_called_non_existent_job_pane = setStatus called for non-existent job pane {0}\r
+error.implementation_error_cannot_find_marshaller_for_param_set =Implementation error: Can't find a marshaller for the parameter set\r
+error.implementation_error_old_jalview_object_not_bound =IMPLEMENTATION ERROR: old jalview object is not bound ! ({0})\r
+error.implementation_error_vamsas_doc_class_should_bind_to_type = Implementation Error: Vamsas Document Class {0} should bind to a {1} (found a {2})\r
+error.implementation_error_jalview_class_should_bind_to_type = Implementation Error: Jalview Class {0} should bind to a {1} (found a {2})\r
+error.invalid_vamsas_rangetype_cannot_resolve_lists = Invalid vamsas RangeType - cannot resolve both lists of Pos and Seg from choice!\r
+error.implementation_error_maplist_is_null = Implementation error. MapList is null for initMapType.\r
+error.implementation_error_cannot_have_null_alignment = Implementation error: Cannot have null alignment property key\r
+error.implementation_error_null_fileparse = Implementation error. Null FileParse in copy constructor\r
+error.implementation_error_cannot_map_alignment_sequences = IMPLEMENTATION ERROR: Cannot map an alignment of sequences from different datasets into a single alignment in the vamsas document.\r
+error.implementation_error_cannot_duplicate_colour_scheme = Serious implementation error: cannot duplicate colourscheme {0}\r
+error.implementation_error_structure_selection_manager_null = Implementation error. Structure selection manager's context is 'null'\r
+exception.ssm_context_is_null = SSM context is null\r
+error.idstring_seqstrings_only_one_per_sequence = idstrings and seqstrings contain one string each per sequence\r
+error.cannot_have_mixed_length_replacement_vectors = Cannot have mixed length replacement vectors. Replacement vector for {0} is {1} strings long, and have already seen a {2} length vector.\r
+error.cannot_have_zero_length_vector_replacement_strings = Cannot have zero length vector of replacement strings - either 1 value or n values.\r
+error.implementation_error_multiple_single_sequence_prediction_jobs_not_supported = Implementation Error! Multiple single sequence prediction jobs are not yet supported\r
+error.implementation_error_invalid_msa_index_for_job =Implementation Error! Invalid msaIndex for JPredJob on parent MSA input object!\r
+error.implementation_error_startjob_called = Implementation error - StartJob(JpredJob) called on {0}\r
+error.multiple_jnet_subjob_merge_not_implemented = Multiple JNet subjob merging not yet implemented\r
+label.job_never_ran = Job never ran - input returned to user.\r
+error.implementation_error_minlen_must_be_greater_zero = Implementation error: minlen must be zero or more\r
+error.implementation_error_msawbjob_called = Implementation error - StartJob(MsaWSJob) called on a WSJobInstance {0}\r
+error.implementation_error_cannot_attach_ws_menu_entry = IMPLEMENTATION ERROR: cannot attach WS Menu Entry without service handle reference!\r
+error.parameter_migration_not_implemented_yet = Parameter migration not implemented yet\r
+error.implementation_error_cannot_set_jaba_option = Implementation error: cannot set Jaba Option to a value outside its allowed value range!\r
+error.implementation_error_valuetype_doesnt_support_jabaws_type = IMPLEMENTATION ERROR: jalview.ws.params.ValueConstrainI.ValueType does not support the JABAWS type : {0}\r
+error.cannot_create_jabaws_param_set = Cannot create a JabaWSParamSet from non-JabaWS parameters\r
+error.cannot_set_arguments_to_jabaws_param_set = Cannot set arguments to a JabaWSParamSet that are not JabaWS arguments\r
+error.implementation_error_runner_config_not_available = Implementation Error: Runner Config not available for a JABAWS service of type {0} ({1})\r
+error.implementation_error_cannot_handle_jaba_param = Implementation Error: Cannot handle Jaba parameter object {0}\r
+error.implementation_error_attempt_to_delete_service_preset = Implementation error: Attempt to delete a service preset!\r
+error.implementation_error_cannot_locate_oldname_presetname = Implementation error: Can't locate either oldname ({0}) or presetName ({1}in the datastore!"\r
+error.implementation_error_jabaws_param_set_only_handled_by = Implementation error: JabaWsParamSets can only be handled by JabaParamStore\r
+error.cannot_set_source_file_for = Cannot set source file for {0}\r
+error.mismatch_service_instance_preset = Probable mismatch between service instance and preset!\r
+error.cannot_set_params_for_ws_preset = Cannot set Parameters for a Jaba Web service's preset\r
+error.implementation_error_can_only_instantiate_jaba_param_sets = Implementation error: Can only instantiate Jaba parameter sets\r
+error.no_aacon_service_found = No AACon service found\r
+error.implementation_error_couldnt_copy_value_constraint = Implementation error: could not copy ValueConstrain!\r
+error.couldnt_encode_as_utf8 = Couldn't encode {0} as UTF-8.\r
+error.tree_inputtype_not_yet_implemented = Tree InputType not yet implemented\r
+error.implementation_error_need_to_have_httpresponse = Implementation Error: need to have an HttpResponse to process\r
+error.dbrefsource_implementation_exception =DBRefSource Implementation Exception\r
+error.implementation_error_dbinstance_must_implement_interface = Implmentation Error - getDbInstances must be given a class that implements jalview.ws.seqfetcher.DbSourceProxy (was given{0})\r
+error.implementation_error_must_init_dbsources =Implementation error. Must initialise dbSources\r
+label.view_controller_toggled_marked = {0} {1} columns {2} containing features of type {3}  across {4} sequence(s)\r
+label.toggled = Toggled\r
+label.marked = Marked\r
+label.not = not\r
+label.no_feature_of_type_found = No features of type {0} found.\r
+label.submission_params = Submission {0}\r
+label.empty_alignment_job = Empty Alignment Job\r
+label.add_new_sbrs_service = Add a new Simple Bioinformatics Rest Service\r
+label.edit_sbrs_entry = Edit Simple Bioinformatics Rest Service entry\r
+label.pca_recalculating = Recalculating PCA\r
+label.pca_calculating = Calculating PCA\r
+label.select_foreground_colour = Choose foreground colour\r
+label.select_colour_for_text = Select Colour for Text\r
+label.adjunst_foreground_text_colour_thereshold = Adjust Foreground Text Colour Threshold\r
+label.select_subtree_colour = Select Sub-Tree Colour\r
+label.create_new_sequence_features = Create New Sequence Feature(s)\r
+label.amend_delete_features = Amend/Delete Features for {0}\r
+exception.out_of_bounds_for_file = Out of bounds for file: i={0}, Final Buffer: i0={1} iend={2}\r
+exception.null_string_given_to_regex_search = Null String Given to Regex.search\r
+exception.null_string_like_given_to_regex_search = Null StringLike Given to Regex.search\r
+exception.null_string_given_to_regex_reverse_search = Null String Given to Regex.reverseSearch\r
+exception.null_string_like_given_to_regex_reverse_search = Null StringLike Given to Regex.reverseSearch\r
+exception.null_string_like_given_to_regex_search_from = Null String Given to Regex.searchFrom\r
+exception.null_string_like_given_to_regex_search_region = Null String Given to Regex.searchRegion\r
+exception.replace_null_regex_pointer = Replacer has null Regex pointer\r
+exception.bad_pattern_to_regex_perl_code = bad pattern to Regex.perlCode: {0}\r
+exception.no_stub_implementation_for_interface = There is no stub implementation for the interface: {0}\r
+exception.cannot_set_endpoint_address_unknown_port = Cannot set Endpoint Address for Unknown Port {0}\r
+exception.querying_matching_opening_parenthesis_for_non_closing_parenthesis = Querying matching opening parenthesis for non-closing parenthesis character {0}\r
+exception.mismatched_unseen_closing_char = Mismatched (unseen) closing character {0}\r
+exception.mismatched_closing_char = Mismatched closing character {0}\r
+exception.mismatched_opening_char = Mismatched opening character {0} at {1}\r
+exception.invalid_datasource_couldnt_obtain_reader = Invalid datasource. Could not obtain Reader\r
+exception.index_value_not_in_range = {0}: Index value {1} not in range [0..{2}]\r
+exception.unterminated_cigar_string = Unterminated cigar string\r
+exception.unexpected_operation_cigar_string_pos = Unexpected operation {0} in cigar string (position {1} in {2}\r
+exception.couldnt_parse_responde_from_annotated3d_server = Couldn't parse response from Annotate3d server\r
+exception.application_test_npe = Application test: throwing an NullPointerException It should arrive at the console\r
+exception.overwriting_vamsas_id_binding = Overwriting vamsas id binding\r
+exception.overwriting_jalview_id_binding = Overwriting jalview id binding\r
+error.implementation_error_unknown_file_format_string = Implementation error: Unknown file format string\r
+exception.failed_to_resolve_gzip_stream = Failed to resolve GZIP stream\r
+exception.problem_opening_file_also_tried = Problem opening {0} (also tried {1}) : {2}\r
+exception.problem_opening_file = Problem opening {0} : {1}\r
+exception.failed_to_read_data_from_source = Failed to read data from source: {0}\r
+exception.no_init_source_stream = Unitialised Source Stream\r
+exception.invalid_source_stream = Invalid Source Stream: {0}\r
+error.implementation_error_reset_called_for_invalid_source = Implementation Error: Reset called for invalid source.\r
+exception.number_of_residues_in_query_sequence_differ_from_prediction = Number of residues in {0} supposed query sequence ({1}\n{2})\ndiffer from number of prediction sites in prediction ({3})\r
+label.mapped = mapped\r
+exception.jpredconcide_entry_has_unexpected_number_of_columns = JPredConcise: Entry ({0}) has an unexpected number of columns\r
+exception.couldnt_parse_concise_annotation_for_prediction = Couldn't parse concise annotation for prediction profile.\n{0}\r
+exception.newfile = NewickFile\: {0}\n\r
+label.no_tree_read_in = No Tree read in\r
+exception.rnaml_couldnt_access_datasource = Couldn't access datasource ({0})\r
+exception.ranml_couldnt_process_data = Couldn't process data as RNAML file ({0})\r
+exception.ranml_invalid_file = Invalid RNAML file ({0})\r
+exception.ranml_problem_parsing_data = Problem parsing data as RNAML ({0})\r
+exception.pfam_no_sequences_found = No sequences found (PFAM input)\r
+exception.stockholm_invalid_format = This file is not in valid STOCKHOLM format: First line does not contain '# STOCKHOLM'\r
+exception.couldnt_parse_sequence_line = Could not parse sequence line: {0}\r
+exception.error_parsing_line = Error parsing {0}\r
+exception.unknown_annotation_detected = Unknown annotation detected: {0} {1}\r
+exception.couldnt_store_sequence_mappings = Couldn't store sequence mappings for {0}\r
+exception.matrix_too_many_iteration = Too many iterations in {0} (max is {1})\r
+exception.browser_not_found = Exception in finding browser: {0}\r
+exception.browser_unable_to_locate = Unable to locate browser: {0}\r
+exception.invocation_target_exception_creating_aedesc = InvocationTargetException while creating AEDesc: {0}\r
+exception.illegal_access_building_apple_evt= IllegalAccessException while building AppleEvent: {0}\r
+exception.instantiation_creating_aedesc = InstantiationException while creating AEDesc: {0}\r
+exception.unable_to_launch_url = Unable to launch URL: {0}\r
+exception.unable_to_create_internet_config = Unable to create an Internet Config instance: {0}\r
+exception.invocation_target_calling_url = InvocationTargetException while calling openURL: {0}\r
+exception.illegal_access_calling_url = IllegalAccessException while calling openURL: {0}\r
+exception.interrupted_launching_browser = InterruptedException while launching browser: {0}\r
+exception.das_source_doesnt_support_sequence_command = Source {0} does not support the sequence command.\r
+exception.invalid_das_source = Invalid das source: {0}\r
+exception.ebiembl_retrieval_failed_on = EBI EMBL XML retrieval failed on {0}:{1}\r
+label.no_embl_record_found = # No EMBL record retrieved for {0}:{1}\r
+label.embl_successfully_parsed = # Successfully parsed the {0} queries into an Alignment\r
+exception.no_pdb_records_for_chain = No PDB Records for {0} chain {1}\r
+exception.unexpected_handling_rnaml_translation_for_pdb = Unexpected exception when handling RNAML translation of PDB data\r
+exception.couldnt_recover_sequence_properties_for_alignment = Couldn't recover sequence properties for alignment\r
+exception.unknown_format_for_file = Unknown format {0} for file \: \n{1}\r
+label.remove_gaps = Remove Gaps\r
+exception.couldnt_recover_sequence_props_for_jnet_query = Couldn't recover sequence properties for JNet Query sequence!\r
+exception.server_timeout_try_later = Server timed out - try again later\n\r
+exception.web_service_returned_null_try_later= Server at {0} returned null object, it probably cannot be contacted. Try again later.\r
+exception.cannot_contact_service_endpoint_at = Cannot contact service endpoint at {0}\r
+error.implementation_error_cannot_find_service_url_in_given_set = Implementation error: Cannot find service url in the given url set!\r
+error.implementation_error_cannot_find_service_url_in_given_set_param_store = Implementation error: Cannot find service url in the given url set for this service parameter store ({0}}\r
+exception.jobsubmission_invalid_params_set = Invalid parameter set. Check Jalview implementation\r
+exception.notvaliddata_group_contains_less_than_min_seqs = Group contains less than {0} sequences.\r
+exception.outofmemory_loading_pdb_file = Out of memory loading PDB File\r
+exception.eps_coudnt_write_output_file = Could not write to the output file: {0}\r
+exception.eps_method_not_supported = Method not currently supported by EpsGraphics2D version {0}\r
+exception.eps_unable_to_get_inverse_matrix = Unable to get inverse of matrix: {0}\r
+warn.job_cannot_be_cancelled_close_window = This job cannot be cancelled.\nJust close the window.\r
+warn.service_not_supported = Service not supported!\r
+warn.input_is_too_big = Input is too big!\r
+warn.invalid_job_param_set = Invalid job parameter set!\r
+info.job_couldnt_be_run_server_doesnt_support_program = Job could not be run because the server doesn't support this program.\n{0}\r
+info.job_couldnt_be_run_exceeded_hard_limit = Job could not be run because it exceeded a hard limit on the server.\n{0}\r
+info.job_couldnt_be_run_incorrect_param_setting = Job could not be run because some of the parameter settings are not supported by the server.\n{0}\nPlease check to make sure you have used the correct parameter set for this service\!\n\r
+info.no_jobs_ran = No jobs ran\r
+info.failed_to_submit_prediction = Failed to submit the prediction\:\n{0} {1}\r
+info.invalid_jnet_job_result_data ={0}\n{1}\nInvalid JNet job result data\!\n{2}\r
+info.failed_to_submit_sequences_for_alignment = Failed to submit sequences for alignment.\nIt is most likely that there is a problem with the server.\nJust close the window\n\r
+info.alignment_object_method_notes = \nAlignment Object Method Notes\n\r
+info.server_exception = \n{0} Server exception\!\n{1}\r
+status.processing_commandline_args = Processing commandline arguments...\r
+status.das_features_being_retrived = DAS features being retrieved...\r
+status.searching_for_sequences_from = Searching for sequences from {0}\r
+status.finished_searching_for_sequences_from = Finished searching for sequences from {0}\r
+label.eps_file = EPS file\r
+label.png_image = PNG image\r
+status.saving_file = Saving {0}\r
+status.export_complete = Export complete.\r
+status.fetching_pdb = Fetching PDB {0}\r
+status.refreshing_news = Refreshing news\r
+status.importing_vamsas_session_from = Importing VAMSAS session from {0}\r
+status.opening_params = Opening {0}\r
+status.waiting_sequence_database_fetchers_init = Waiting for Sequence Database Fetchers to initialise\r
+status.init_sequence_database_fetchers = Initialising Sequence Database Fetchers\r
+status.fetching_sequence_queries_from = Fetching {0} sequence queries from {1}\r
+status.finshed_querying = Finished querying\r
+status.parsing_results = Parsing results.\r
+status.processing = Processing...\r
+status.refreshing_web_service_menus = Refreshing Web Service Menus\r
+status.collecting_job_results = Collecting job results.\r
+status.fetching_das_sequence_features = Fetching DAS Sequence Features\r
+status.no_das_sources_active = No DAS Sources Active\r
+status.das_feature_fetching_cancelled = DAS Feature Fetching Cancelled\r
+status.das_feature_fetching_complete = DAS Feature Fetching Complete\r
+status.fetching_db_refs = Fetching db refs\r
+label.font_doesnt_have_letters_defined = Font doesn't have letters defined\nso cannot be used\nwith alignment data\r
+label.error_loading_file_params = Error loading file {0}\r
+label.error_loading_jalview_file = Error loading Jalview file\r
+warn.out_of_memory_when_action = Out of memory when {0}\!\!\nSee help files for increasing Java Virtual Machine memory.\r
+warn.out_of_memory_loading_file = Out of memory loading file {0}\!\!\nSee help files for increasing Java Virtual Machine memory.\r
+label.out_of_memory = Out of memory\r
+label.invalid_id_column_width = Invalid ID Column width\r
+warn.user_defined_width_requirements = The user defined width for the\nannotation and sequence ID columns\nin exported figures must be\nat least 12 pixels wide.\r
+label.couldnt_create_sequence_fetcher = Couldn't create SequenceFetcher\r
+warn.couldnt_create_sequence_fetcher_client = Could not create the sequence fetcher client. Check error logs for details.\r
+warn.server_didnt_pass_validation = Service did not pass validation.\nCheck the Jalview Console for more details.\r
+warn.url_must_contain = Sequence URL must contain $SEQUENCE_ID$ or a regex $SEQUENCE_ID=/<regex>/=$\r
+info.validate_jabaws_server = Validate JabaWS Server ?\n(Look in console output for results)\r
+label.test_server = Test Server?\r
+info.you_want_jalview_to_find_uniprot_accessions = Do you want Jalview to find\nUniprot Accession ids for given sequence names?\r
+label.find_uniprot_accession_ids = Find Uniprot Accession Ids\r
+label.new_sequence_fetcher = New Sequence Fetcher\r
+label.additional_sequence_fetcher = Additional Sequence Fetcher\r
+label.select_database_retrieval_source = Select Database Retrieval Source\r
+label.overwrite_existing_file = Overwrite existing file?\r
+label.file_already_exists = File exists\r
+label.edit_jabaws_url = Edit JABAWS URL\r
+label.add_jabaws_url = Add new JABAWS URL\r
+label.news_from_jalview = News from http://www.jalview.org\r
+label.cut_paste_alignmen_file = Cut & Paste Alignment File\r
+label.enter_redundancy_thereshold = Enter the redundancy thereshold\r
+label.select_dark_light_set_thereshold = <html><i>Select a dark and light text colour, then set the threshold to<br>switch between colours, based on background colour</i></html>\r
+label.select_feature_colour = Select Feature Colour
\ No newline at end of file
index c1fb406..066f919 100644 (file)
@@ -1,7 +1,801 @@
+action.refresh_services = Refrescar servicios\r
+action.reset_services = Reiniciar servicios\r
+action.merge_results = Unificar resultados\r
+action.load_scheme = Cargar esquema\r
+action.save_scheme = Guardar esquema\r
+action.save_image = Guardar imagen\r
+action.paste = Pegar\r
+action.show_html_source = Mostrar código HTML\r
+action.print = Imprimir\r
+action.web_service = Servicio web\r
+action.cancel_job = Cancelar trabajo\r
+action.start_job = Arrancar trabajo\r
+action.revert = Deshacer\r
+action.move_down = Mover hacia abajo\r
+action.move_up = Mover hacia arriba\r
+action.remove_return_datatype = Borrar tipo de datos de retorno\r
+action.add_return_datatype = Añadir tipo de datos de retorno\r
+action.remove_input_parameter = Borrar el parámetro de entrada seleccionado\r
+action.add_input_parameter = Añadir parámetro de entrada seleccionado\r
+action.edit = Editar\r
+action.new = Nuevo\r
+action.open_file = Abrir fichero\r
+action.show_unconserved = Mostrar regiones no conservadas\r
+action.open_new_aligmnent = Abrir nuevo alineamiento\r
+action.raise_associated_windows = Destacar ventanas asociadas\r
+action.minimize_associated_windows = Minimizar ventanas asociadas\r
+action.close_all = Cerrar todo\r
+action.load_project = Cargar proyecto\r
+action.save_project = Guardar proyecto\r
+action.quit = Salir\r
+action.expand_views = Expandir vistas\r
+action.gather_views = Capturar vistas\r
+action.page_setup = Configuración de la página\r
+action.reload = Recargar\r
+action.load = Cargar\r
+action.open = Abrir\r
 action.cancel = Cancelar\r
 action.create = Crear\r
 action.update = Actualizar\r
 action.delete = Borrar\r
-action.snapshot = Captura\r
+action.snapshot = Imagen\r
 action.clear = Limpiar\r
 action.accept = Aceptar\r
+action.select_ddbb = --- Seleccionar base de datos ---\r
+action.undo = Deshacer\r
+action.redo = Rehacer\r
+action.reset = Reiniciar\r
+action.remove_left = Eliminar parte izquierda\r
+action.remove_right = Eliminar parte derecha\r
+action.remove_empty_columns = Eliminar las columnas vacías\r
+action.remove_all_gaps = Eliminar todos los huecos\r
+action.left_justify_alignment = Ajustar el alineamiento a la izquierda\r
+action.right_justify_alignment = Ajustar el alineamiento a la derecha\r
+action.boxes = Casillas\r
+action.text = Texto\r
+action.by_pairwise_id = Identificar por parejas\r
+action.by_id = Por identificador\r
+action.by_length = Por longitud\r
+action.by_group = Por grupo\r
+action.remove = Eliminar\r
+action.remove_redundancy = Eliminar redundancia...\r
+action.pairwise_alignment = Alineamiento de pares...\r
+action.by_rna_helixes = Por hélices de RNA\r
+action.user_defined = Definido por el usuario...\r
+action.by_conservation = Por conservación\r
+action.wrap = Envolver\r
+action.show_gaps = Mostrar huecos\r
+action.show_hidden_markers = Mostrar marcadores ocultos\r
+action.find = Buscar\r
+action.undefine_groups = Grupos sin definir\r
+action.create_groups = Crear grupos\r
+action.make_groups_selection = Hacer grupos para seleccionar\r
+action.copy = Copiar\r
+action.cut = Cortar\r
+action.font = Fuente...\r
+action.scale_above = Escala superior\r
+action.scale_left = Escala izquierda\r
+action.scale_right = Escala derecha\r
+action.by_tree_order = Por orden del árbol\r
+action.sort = Ordenar\r
+action.calculate_tree = Calcular árbol\r
+action.help = Ayuda\r
+action.by_annotation = Por anotación...\r
+action.invert_sequence_selection = Invertir selección de secuencias\r
+action.invert_column_selection = Invertir selección de columnas\r
+action.show = Mostrar\r
+action.hide = Ocultar\r
+action.ok = OK\r
+action.set_defaults = Defecto\r
+action.create_group = Crear grupo\r
+action.remove_group = Eliminar grupo\r
+action.edit_group = Editar grupo\r
+action.border_colour = Color del borde\r
+action.edit_new_group = Editar nuevo grupo\r
+action.hide_sequences = Ocultar secuencias\r
+action.sequences = Secuencias\r
+action.ids = IDS\r
+action.ids_sequences = IDS y secuencias\r
+action.reveal_all = Revelar todo\r
+action.reveal_sequences = Revelar secuencias\r
+action.find_all = Buscar todo\r
+action.find_next = Buscar siguiente\r
+action.file = Archivo\r
+action.view = Ver \r
+action.change_params = Cambiar parámetros\r
+action.apply = Aplicar\r
+action.apply_threshold_all_groups = Aplicar umbral a todos los grupos\r
+action.apply_all_groups = Aplicar a todos los grupos\r
+action.by_chain = Por cadena\r
+action.by_sequence = Por secuencia\r
+action.paste_annotations = Pegar anotaciones\r
+action.format = Formato\r
+action.select = Seleccionar\r
+action.new_view = Nueva vista\r
+action.close = Cerrar\r
+action.add = Añadir\r
+action.save_as_default = Guardar como por defecto\r
+action.save_as = Guardar como\r
+action.save = Guardar\r
+action.cancel_fetch = Cancelar búsqueda\r
+action.save_omit_hidden_columns = Guardar / Omitir las columnas ocultas\r
+action.change_font = Cambiar Fuente\r
+action.change_font_tree_panel = Cambiar fuente (panel del árbol)\r
+action.colour = Color\r
+action.calculate = Calcular\r
+action.select_all = Seleccionar Todo\r
+action.deselect_all = Deseleccionar Todo\r
+action.invert_selection = Invertir selección\r
+action.using_jmol = Usar Jmol\r
+action.link = Enlazar\r
+action.group_link = Enlazar grupo\r
+action.show_chain = Mostrar cadena\r
+action.show_group = Mostrar grupo\r
+action.fetch_db_references = Recuperar referencias a base de datos\r
+action.view_flanking_regions = Mostrar flancos\r
+label.view_flanking_regions = Mostrar los datos de la secuencia a ambos lados de las subsecuencias implicadas en este alineamiento\r
+label.str = Str: \r
+label.seq = Seq: \r
+label.structures_manager = Administrar estructuras\r
+label.nickname = Sobrenombre:\r
+label.url = URL: \r
+label.input_file_url = Introducir URL en el fichero de entrada\r
+label.select_feature = Seleccionar función:\r
+label.name = Nombre:\r
+label.name_param = Nombre: {0}\r
+label.group = Grupo:\r
+label.group_name = Nombre del grupo\r
+label.group_description = Descripción del grupo\r
+label.edit_group_name_description = Editar nombre/descripción del grupo\r
+label.colour = Color:\r
+label.description = Descripción:\r
+label.start = Comenzar:\r
+label.end = Terminar:\r
+label.current_parameter_set_name = Nombre actual del conjunto de parámetros:\r
+label.service_action = Acción de servicio:\r
+label.post_url = POST URL: \r
+label.url_suffix = URL Sufijo\r
+label.sequence_source = Fuente de la secuencia\r
+label.per_seq = por secuencia\r
+label.result_vertically_separable = Los resultados son separables verticalmente\r
+label.amend = Modificar\r
+label.undo_command = Deshacer {0}\r
+label.redo_command = Rehacer {0}\r
+label.principal_component_analysis = Análisis del Componente Principal\r
+label.average_distance_identity = Distancia Media Usando % de Identidad\r
+label.neighbour_joining_identity = Unir vecinos utilizando % de Identidad\r
+label.treecalc_title = {0} utilizando {1}\r
+label.tree_calc_av = Distancia media\r
+label.tree_calc_nj = Unir vecinos\r
+label.select_score_model = Selecciones modelo de puntuación\r
+label.score_model_pid = % Identidad\r
+label.score_model_blosum62 = BLOSUM62\r
+label.score_model_pam250 = PAM 250\r
+label.score_model_conservation = Conservación de las propiedades físico-químicas\r
+label.score_model_enhconservation = Conservación de las propiedades físico-químicas\r
+label.status_bar = Barra de estado\r
+label.out_to_textbox = Generar cuadro de texto\r
+label.clustalx = Clustalx\r
+label.clustal = Clustal\r
+label.zappo = Zappo\r
+label.taylor = Taylor\r
+label.blc = BLC\r
+label.fasta = Fasta\r
+label.msf = MSF\r
+label.pfam = PFAM\r
+label.pileup = Pileup\r
+label.pir = PIR\r
+label.hydrophobicity = Hidrofobicidad\r
+label.helix_propensity = Tendencia de la hélice\r
+label.strand_propensity = Tendencia de la hebra\r
+label.turn_propensity = Tendencia de giro\r
+label.buried_index = Índice de encubrimiento\r
+label.purine_pyrimidine = Purina/Pirimidina\r
+label.percentage_identity = Porcentaje de identidad\r
+label.blosum62 = BLOSUM62\r
+label.blosum62_score = Puntuación del BLOSUM62 \r
+label.tcoffee_scores = Puntuación del T-Coffee\r
+label.average_distance_bloslum62 = Distancia Media Usando BLOSUM62\r
+label.neighbour_blosum62 = Neighbour Joining usando BLOSUM62\r
+label.show_annotations = Mostrar anotaciones\r
+label.colour_text = Color del texto\r
+label.show_non_conversed = Mostrar no conservadas\r
+label.overview_window = Ventana resumen\r
+label.none = Ninguno\r
+label.above_identity_threshold = Por encima del umbral de identidad\r
+label.show_sequence_features = Mostrar las características de las secuencias\r
+label.nucleotide = Nucleótido\r
+label.to_new_alignment = A nuevo alineamiento\r
+label.to_this_alignment = Añadir a este alineamiento\r
+label.apply_colour_to_all_groups = Aplicar color a todos los grupos\r
+label.modify_identity_thereshold = Modificar el umbral de identidad...\r
+label.modify_conservation_thereshold = Modificar el umbral de conservación...\r
+label.input_from_textbox = Introducir desde el cuadro de texto\r
+label.centre_column_labels = Centrar las etiquetas de las columnas\r
+label.automatic_scrolling = Desplazamiento automático\r
+label.documentation = Documentación\r
+label.about = Acerca de...\r
+label.show_sequence_limits = Mostrar los límites de la secuencia\r
+label.feature_settings = Ajustar funciones...\r
+label.sequence_features = Funciones de la secuencia\r
+label.all_columns = Todas las columnas\r
+label.all_sequences = Todas las secuencias\r
+label.selected_columns = Columnas seleccionadas\r
+label.selected_sequences = Secuencias seleccionadas\r
+label.all_but_selected_region = Todo menos la región seleccionada (Shift+Ctrl+H)\r
+label.selected_region = Región seleccionada\r
+label.all_sequences_columns = Todas las secuencias y columnas\r
+label.group_consensus = Consenso de grupo\r
+label.group_conservation = Conservación de grupo\r
+label.show_consensus_histogram = Mostrar el histograma de consenso\r
+label.show_consensus_logo = Mostrar el logo de consenso\r
+label.norm_consensus_logo = Normalizar el logo de consenso\r
+label.apply_all_groups = Aplicar a todos los grupos\r
+label.autocalculated_annotation = Anotación autocalculada\r
+label.min_colour = Color mínimo\r
+label.max_colour = Color máximo\r
+label.use_original_colours = Usar colores originales\r
+label.threshold_minmax = El umbral es mín/máx\r
+label.represent_group_with = Representar al grupo con\r
+label.selection = Seleccionar\r
+label.group_colour = Color del grupo\r
+label.sequence = Secuencia\r
+label.view_pdb_structure = Ver estructura PDB\r
+label.min = Mín:\r
+label.max = Máx:\r
+label.colour_by_label = Color por etiquetas\r
+label.new_feature = Nueva función\r
+label.match_case = Hacer corresponder mayúsculas y minúsculas\r
+label.view_alignment_editor = Ver en el editor de alineamientos\r
+label.labels = Etiquetas\r
+label.output_values = Valores de salida...\r
+label.output_points = Puntos de salida...\r
+label.output_transformed_points = Puntos de salida transformados\r
+label.input_data = Datos de entrada...\r
+label.nucleotide_matrix = Matriz nucleotídica\r
+label.protein_matrix = Matriz proteica\r
+label.show_bootstrap_values = Mostrar valores de Bootstrap\r
+label.show_distances = Mostrar distancias\r
+label.mark_unassociated_leaves = Marcar hojas no asociadas\r
+label.fit_to_window = Ajustar a la ventana\r
+label.newick_format = Formato Newick\r
+label.select_newick_like_tree_file = Seleccione un fichero de árbol tipo Newick\r
+label.colours = Colores\r
+label.view_mapping = Ver mapeado\r
+label.wireframe = Estructura metálica\r
+label.depthcue = Clave de profundidad\r
+label.z_buffering = Tamponamiento Z\r
+label.charge_cysteine = Carga & Cisteína\r
+label.all_chains_visible = Todas las cadenas visibles\r
+label.successfully_added_features_alignment = Funciones añadidas exitosamente al alineamiento\r
+label.keyboard_editing_mode = El modo de editar teclado es {0}\r
+label.paste_features_annotations_Tcoffee_here = Pegar tus funciones / anotaciones / puntuación del fichero T-coffee aquí.\r
+label.removed_columns = {0} columnas eliminadas.\r
+label.removed_empty_columns = {0} columnas vacías eliminadas.\r
+label.paste_newick_tree_file = Pegar su fichero árbol Newick aquí. \r
+label.order_by_params = Ordenar por {0}\r
+label.html_content = <html>{0}</html>\r
+label.paste_pdb_file= Pegar tu fichero PDB aquí.\r
+label.paste_pdb_file_for_sequence = Pegar fichero PDB para la secuencia {0}\r
+label.could_not_parse_newick_file  = No se pudo analizar el fichero Newick\\\!\\n {0}\r
+label.successfully_pasted_tcoffee_scores_to_alignment= Pegada exitosamente la puntuación T-Coffee al alineamiento.\r
+label.failed_add_tcoffee_scores = Fallo al añadir las puntuaciones T-Coffee: \r
+label.successfully_pasted_annotation_to_alignment = Anotación pegada exitosamente al alineamiento.\r
+label.couldnt_parse_pasted_text_as_valid_annotation_feature_GFF_tcoffee_file = No es posible parsear el texto pegado como una anotación características, GFF, o fichero T-Coffee válidos\r
+label.successfully_pasted_alignment_file = Fichero de alineamiento pegado exitosamente\r
+label.paste_your_alignment_file = Pegar su fichero de alineamiento aquí\r
+label.paste_your = Pegar su\r
+label.finished_searching = Búsqueda finalizada\r
+label.search_results= Buscar Resultados {0} : {1}\r
+label.found_match_for = Buscar coincidencia para {0}\r
+label.font = Fuente:\r
+label.size = Talla:\r
+label.style = Estilo:\r
+label.enter_redundancy_threshold = Introducir el umbral de redundancia\r
+label.calculating = Calculando....\r
+label.modify_conservation_visibility = Modificar la visibilidad de conservación\r
+label.colour_residues_above_occurence = Residuos de color por encima del % de aparición \r
+label.set_this_label_text = fijar como etiqueta \r
+label.sequences_from = Secuencias de {0}\r
+label.successfully_loaded_file  = Fichero cargado exitosamente {0}\r
+label.successfully_saved_to_file_in_format = Guardado exitosamente en el fichero: {0} en formato {1}.\r
+label.copied_sequences_to_clipboard = Copiadas {0} secuencias en el portapapeles.\r
+label.check_file_matches_sequence_ids_alignment = Comprobar que el fichero coincide con el ID de la secuencia en el alineamiento.\r
+label.problem_reading_tcoffee_score_file = Problema de lectura del fichero de puntuaciones T-COFFEE\r
+label.source_to_target = {0} a '{1}'\r
+label.per_sequence_only= Sólo por secuencia\r
+label.to_file = a fichero\r
+label.to_textbox = a cuadro de texto\r
+label.jalview = Jalview\r
+label.csv_spreadsheet = CSV (Hoja de cálculo)\r
+label.status =  [Estado]\r
+label.channels = Canales\r
+label.channel_title_item_count = {0} ({1})\r
+label.blog_item_published_on_date = {0} {1} \r
+label.select_das_service_from_table = Seleccionar servicio DAS de la tabla para leer una descripción completa aquí.\r
+label.session_update = Actualizar sesión\r
+label.new_vamsas_session = Nueva sesión Vamsas\r
+label.load_vamsas_session = Cargar sesión Vamsas\r
+label.save_vamsas_session = Guardar sesión Vamsas\r
+label.select_vamsas_session_opened_as_new_vamsas_session= Selecciones una sesión vamsas para abrirla como una nueva sesión.\r
+label.open_saved_vamsas_session = Abrir una sesión VAMSAS guardada\r
+label.groovy_console = Consola Groovy \r
+label.lineart = lineart\r
+label.dont_ask_me_again = No volver a preguntar\r
+label.select_eps_character_rendering_style = Seleccionar el carácter EPS como estilo de visualización \r
+label.invert_selection = Invertir selección\r
+label.optimise_order = Optimizar orden\r
+label.seq_sort_by_score = Ordenar las secuencias por puntuación\r
+label.load_colours = Cargar colores\r
+label.save_colours = Guardar colores\r
+label.fetch_das_features = Recuperar funciones DAS\r
+label.selected_database_to_fetch_from = Seleccionada {0} Base de datos {1} para buscar de {2} \r
+label.database_param = Base de datos: {0}\r
+label.example = Ejemplo\r
+label.example_param = Ejemplo: {0}\r
+label.select_file_format_before_saving = Debe seleccionar un formato de fichero antes de guardar!\r
+label.file_format_not_specified = Formato de fichero no especificado\r
+label.alignment_contains_hidden_columns = El alineamiento contiene columnas ocultas.\\nQuieres guardar s\u00F3lo el alineamiento visible?\r
+label.couldnt_save_file = No se pudo guardar el fichero: {0}\r
+label.error_saving_file = Error guardando el fichero\r
+label.remove_from_default_list = eliminar de la lista de defectuosos?\r
+label.remove_user_defined_colour = Eliminar el color definido por el usuario\r
+label.you_must_select_least_two_sequences = Debes seleccionar al menos 2 secuencias.\r
+label.invalid_selection = Selección inválida\r
+label.principal_component_analysis_must_take_least_four_input_sequences = El an\u00E1lisis de la componente principal debe tomar\\nal menos 4 secuencias de entrada.\r
+label.sequence_selection_insufficient = Selección de secuencias insuficiente\r
+label.you_need_more_two_sequences_selected_build_tree = necesitas seleccionar más de dos secuencias para construir un árbol!\r
+label.not_enough_sequences = No suficientes secuencias\r
+label.selected_region_to_tree_may_only_contain_residues_or_gaps = La regi\u00F3n seleccionada para construir un \u00E1rbol puede\\ncontener s\u00F3lo residuos o espacios.\\nPrueba usando la funci\u00F3n Pad en el men\u00FA de edici\u00F3n,\\n o uno de los m\u00FAltiples servicios web de alineamiento de secuencias.\r
+label.sequences_selection_not_aligned = Las secuencias seleccionadas no están alineadas\r
+label.sequences_must_be_aligned_before_creating_tree = Las secuencias deben estar alineadas antes de crear el \u00E1rbol.\\nPrueba usando la funci\u00F3n Pad en el men\u00FA de editar,\\n o uno de los m\u00FAltiples servicios web de alineamiento de secuencias.\r
+label.sequences_not_aligned = Secuencias no alineadas\r
+label.problem_reading_tree_file =  Problema al leer el fichero del árbol\r
+label.possible_problem_with_tree_file = Posible problema con el fichero del árbol\r
+label.select_at_least_three_bases_in_at_least_one_sequence_to_cDNA_translation = Por favor seleccionar al menos tres bases de al menos una secuencia para poder realizar la traducción de cDNA.\r
+label.translation_failed = Translation Failed\r
+label.error_when_translating_sequences_submit_bug_report = Desafortunadamente, algo fue mal a la hora de traducir tus secuencias.\\nPor favor, revisa la consola Jalview java \\ny presenta un informe de error que incluya el seguimiento.\r
+label.implementation_error  = Error de implementación:\r
+label.automatically_associate_pdb_files_with_sequences_same_name = Quieres asociar automáticamente los {0} ficheros PDB con las secuencias del alineamiento que tengan el mismo nombre?\r
+label.automatically_associate_pdb_files_by_name = Asociar los ficheros PDB por nombre automáticamente\r
+label.ignore_unmatched_dropped_files_info = Quieres <em>ignorar</em> los {0} ficheros cuyos nombres no coincidan con ningún IDs de las secuencias ?\r
+label.ignore_unmatched_dropped_files = Ignorar los ficheros sin coincidencias?\r
+label.enter_view_name = Introducir nombre visible (¿?)\r
+label.enter_label = Introducir etiqueta\r
+label.enter_label_for_the_structure = Introducir una etiqueta para la estructura?\r
+label.pdb_entry_is_already_displayed = {0} Ya est\u00E1 mostrado.\\nQuieres volver a usar este visor?\r
+label.map_sequences_to_visible_window = Mapa de secuencias en ventana visible: {0}\r
+label.add_pdbentry_to_view = Quieres a\u00F1adir {0} a la vista llamada\\n'{1}'\\n\r
+label.align_to_existing_structure_view = Alinear a una estructura ya existente\r
+label.pdb_entries_couldnt_be_retrieved = Las siguientes entradas pdb no pueden ser extra\u00EDdas del PDB\\\:\\n{0}\\nPor favor, prueba descarg\u00E1ndolas manualmente.\r
+label.couldnt_load_file = No se pudo cargar el fichero\r
+label.couldnt_find_pdb_id_in_file = No se pudo encontrar un Id PDB en el fichero suministrado. Por favor, introduzca un Id para identificar esta estructura.\r
+label.no_pdb_id_in_file = No hay un Id PDB en el fichero\r
+label.couldnt_read_pasted_text = No se pudo leer el texto pegado {0}\r
+label.error_parsing_text = Error analizando el texto\r
+label.enter_local_das_source = Intruduzca el Nickname & URL de la fuente DAS local\r
+label.you_can_only_edit_or_remove_local_das_sources = Sólo puedes editar o eliminar fuentes DAS locales!\r
+label.public_das_source = Fuente pública DAS - no editable\r
+label.input_alignment_from_url = Alineamiento de entrada desde URL\r
+label.input_alignment = Alineamiento de entrada\r
+label.couldnt_import_as_vamsas_session = No se pudo importar '{0}' como una nueva sesión Vamsas.\r
+label.vamsas_document_import_failed =  Fallo en la importación del documento Vamsas\r
+label.couldnt_locate = No se pudo localizar {0}\r
+label.url_not_found = URL no encontrada\r
+label.no_link_selected = Enlace no seleccionado\r
+label.new_sequence_url_link = Enlace a una nueva secuencia URL\r
+label.cannot_edit_annotations_in_wrapped_view = No se pueden editar anotaciones en vista envolvente\r
+label.wrapped_view_no_edit = Vista envolvente - no editar\r
+label.error_retrieving_data = Error en la recuperación de datos\r
+label.user_colour_scheme_must_have_name = El esquema de colores del usuario debe tener un nombre\r
+label.no_name_colour_scheme = No hay nombre para el esquema de colores \r
+label.invalid_url = URL Invalido!\r
+label.error_loading_file = Error al cargar el fichero\r
+label.problems_opening_file = Encontrados problemas al abrir el fichero {0}!!\r
+label.file_open_error = Error al abrir el fichero\r
+label.no_das_sources_selected_warn = No han sido seleccionadas fuentes DAS.\\nPor favor, seleccione algunas fuentes y\\npruebe de nuevo.\r
+label.no_das_sources_selected_title = No han sido seleccionadas fuentes DAS\r
+label.colour_scheme_exists_overwrite = El esquema de colores {0} ya existe.\\nContinuar guardando el esquema de colores como {1}?"\r
+label.duplicate_scheme_name = Duplicar nombre de esquema\r
+label.jalview_new_questionnaire = Hay un nuevo cuestionario disponible. Querr\u00EDa completarlo ahora ?\\n\r
+label.jalview_user_survey = Encuesta de usuario Jalview \r
+label.alignment_properties = Propiedades del alineamiento: {0}\r
+label.alignment_props = Propiedades del alineamiento\r
+label.input_cut_paste = Cortar y pegar la entrada\r
+label.input_cut_paste_params = Cortar y pegar la entrada - {0}\r
+label.alignment_output_command = Alineamiento de salida - {0}\r
+label.annotations = Anotaciones\r
+label.features = Funciones\r
+label.overview_params = Visión general {0}\r
+label.paste_newick_file = Pegar nuevo fichero Newick\r
+label.load_tree_from_file = desde fichero - \r
+label.colour_by_annotation = Color por anotación\r
+label.selection_output_command = Seleccionar salida - {0}\r
+label.annotation_for_displayid = <p><h2>Anotación para {0} </h2></p><p>\r
+label.pdb_sequence_mapping = PDB - Mapeado de secuencia\r
+label.pca_details = detalles de la PCA\r
+label.redundancy_threshold_selection = Selección del umbral de redundancia\r
+label.user_defined_colours = Colores definidos del usuario\r
+label.jalviewLite_release = JalviewLite - versión {0}\r
+label.jaview_build_date = Fecha de creación: {0}\r
+label.jalview_authors_1 = Authors:  Jim Procter, Andrew Waterhouse, Jan Engelhardt, Lauren Lui,\r
+label.jalview_authors_2 = Michele Clamp, James Cuff, Steve Searle, David Martin & Geoff Barton.\r
+label.jalview_dev_managers = Desarrollo gestionado por The Barton Group, University of Dundee, Scotland, UK.\r
+label.jalview_distribution_lists = Para ayuda, ver el FAQ at www.jalview.org y/o adjuntar la lista de envío jalview-discuss@jalview.org\r
+label.jalview_please_cite = Si usa Jalview incluya la siguiente cita, por favor:\r
+label.jalview_cite_1_authors = Waterhouse, A.M., Procter, J.B., Martin, D.M.A, Clamp, M. and Barton, G. J. (2009)\r
+label.jalview_cite_1_title = Jalview Version 2 - un editor de alineamiento múltiple de secuencias y banco de trabajo de análisis\r
+label.jalview_cite_1_ref =  Bioinformaticos doi: 10.1093/bioinformatics/btp033\r
+label.right_click = clic en el botón derecho\r
+label.to_add_annotation = para añadir anotación\r
+label.alignment_has_no_annotations = El alineamiento no tiene anotaciones\r
+label.retrieving_pdb_data = Recuperación de datos PDB...\r
+label.label = Etiqueta\r
+label.no_features_added_to_this_alignment = No hay funciones asociadas a este alineamiento!!\r
+label.features_can_be_added_from_searches_1 = (Las funciones pueden ser añadidas de búsquedas o\r
+label.features_can_be_added_from_searches_2 = de ficheros de funciones Jalview / GFF)\r
+label.calculating_pca= Calculando PCA\r
+label.reveal_columns = Mostrar Columnas\r
+label.jalview_cannot_open_file = Jalview no puede abrir el fichero\r
+label.jalview_applet = Aplicación Jalview  \r
+label.loading_data = Cargando datos\r
+label.memory_stats = Memoria libre total: {0} MB; Memoria máxima: {1} MB; {2} %\r
+label.calculating_tree = Calculando árbol\r
+label.state_queueing = En cola \r
+label.state_running = Procesando\r
+label.state_complete = Completar\r
+label.state_completed = Finalizado\r
+label.state_job_cancelled = ¡Trabajo cancelado!\r
+label.state_job_error = Error del trabajo!\r
+label.server_error_try_later = ¡Error del servidor! (Intentar más tarde)\r
+label.error_loading_pdb_data = ¡Error cargando los datos PDB!\r
+label.fetching_pdb_data = Buscando los datos PDB...\r
+label.structure_type = Estructura_tipo\r
+label.settings_for_type = Ajustes para {0}\r
+label.view_full_application = Ver en la aplicación completa \r
+label.load_associated_tree = Cargar árbol asociado ...\r
+label.load_features_annotations = Cargar características/anotaciones ...\r
+label.export_features = Exportar características...\r
+label.export_annotations = Exportar anotaciones ...\r
+label.jalview_copy = Copiar (sólo Jalview)\r
+label.jalview_cut = Cortar (sólo Jalview)\r
+label.to_upper_case = Pasar a mayúsculas\r
+label.to_lower_case = Pasar a minúsculas\r
+label.toggle_case = Alternar mayúsculas y minúsculas\r
+label.edit_name_description = Editar nombre/descripción\r
+label.create_sequence_feature = Crear función de secuencia\r
+label.edit_sequence = Editar secuencia\r
+label.edit_sequences = Editar secuencias\r
+label.sequence_details = Detalles de la secuencia\r
+label.jmol_help = Ayuda de Jmol \r
+label.all = Todo\r
+label.sort_by = Ordenar por\r
+label.sort_by_score = Ordenar por puntuación\r
+label.sort_by_density = Ordenar por densidad\r
+label.sequence_sort_by_density = Ordenar las secuencias por densidad\r
+label.reveal = Revelar\r
+label.hide_columns = Ocultar columnas\r
+label.load_jalview_annotations = Cargar un fichero de anotación de Jalivew o un fichero de características\r
+label.load_tree_file = Cargar un fichero de árbol\r
+label.retrieve_parse_sequence_database_records_alignment_or_selected_sequences = Recuperar y parsear un registro de secuencia de base de datos para el alineamiento o secuencias actualmente seleccionados\r
+label.standard_databases = Bases de datos estándar\r
+label.fetch_embl_uniprot = Recuperar de EMBL/EMBLCDS o Uniprot/PDB y de cualquier fuente DAS seleccionada\r
+label.reset_min_max_colours_to_defaults = Reiniciar los colores min y max colours a los valores por defecto establecidos en las preferencias de usuario\r
+label.align_structures_using_linked_alignment_views = Alinear las estructuras utlizando las {0} vistas de alineamiento enlazadas\r
+label.connect_to_session = Conectar a la sesión {0}\r
+label.threshold_feature_display_by_score = Filtrar la característica mostrada por puntuación.\r
+label.threshold_feature_no_thereshold = Sin umbral\r
+label.threshold_feature_above_thereshold = Por encima del umbral\r
+label.threshold_feature_below_thereshold = Por debajo del umbral\r
+label.adjust_thereshold = Ajustar umbral\r
+label.toggle_absolute_relative_display_threshold = Cambiar entre mostrar el umbral absoluto y el relativo.\r
+label.display_features_same_type_different_label_using_different_colour = Mostrar las características del mismo tipo con una etiqueta diferente y empleando un color distinto (p.e. características del dominio)\r
+label.select_colour_minimum_value = Seleccionar el color para el valor mínimo\r
+label.select_colour_maximum_value = Seleccionar el color para el valor máximo\r
+label.open_new_jmol_view_with_all_structures_associated_current_selection_superimpose_using_alignment = Abrir una nueva vista Jmol con todas las estructuras asociadas con la selección acxtual y superponer las utilizando el alineamiento.\r
+label.open_url_param = Abrir URL {0}\r
+label.open_url_seqs_param = Abrir URL ({0}..) ({1} secuencias)\r
+label.load_pdb_file_associate_with_sequence = Cargar un fichero PDB y asociarlo con la secuencia '{0}'\r
+label.reveal_hidden_columns = Revelar las columnas ocultas con el botón derecho del ratón\r
+label.dark_colour = Oscurecer color\r
+label.light_colour = Aclarar color\r
+label.highlightnode = Pulse el botón izquierdo para seleccionar las hojas.<br>Haga doble clic para invertir las hojas.<br>Pulse el botón derecho para cambiar el color.\r
+label.load_colour_scheme = Cargar esquema cromático\r
+label.toggle_enabled_views = Cuando está habilitado, permite que se seleccionen varias vistas.\r
+label.edit_notes_parameter_set = Haga clic para editar las notas de este conjunto de parámetros.\r
+label.open_local_file = Abrir fichero local\r
+label.enable_automatically_sort_alignment_when_open_new_tree = Habilite esta opción para ordenar automáticamente<br>el alineamiento cuando abra<br> un nuevo árbol.\r
+label.listen_for_selections = Atención a las selecciones\r
+label.selections_mirror_selections_made_same_sequences_other_views = Cuando está habilitado, las selecciones de esta vista serán un reflejo<br>de las selecciones realizadas en las mismas secuencias de otras vistas.\r
+label.toggle_sequence_visibility = Shift+H cambia la visibilidad de la secuencia\r
+label.toggle_columns_visibility = Ctrl+H cambia la visibilidad de la columna\r
+label.toggles_visibility_hidden_selected_regions = H cambiar la visibilidad de las regiones ocultas o seleccionadas\r
+label.rename_tab_eXpand_reGroup=  Haga clic en el botón derecho para renombrar la pestaña<br>Presione X para expandir las tablas y G para reagrupar.\r
+label.right_align_sequence_id = Alinear a la derecha el ID de la secuencia\r
+label.sequence_id_tooltip = Ayuda del ID de la secuencia\r
+label.no_services = <Sin Servicios>\r
+label.select_copy_raw_html = Seleccione esta opción si desea copiar el html en bruto\r
+label.share_data_vamsas_applications = Compartir datos con otras aplicaciones vamsas\r
+label.connect_to = Conectar a\r
+label.join_existing_vamsas_session = Unirse a una sesión vamsas existente\r
+label.from_url = desde una URL\r
+label.any_trees_calculated_or_loaded_alignment_automatically_sort = Cuando está habilitado, cualquier árbol calculado o cargado en el alineamiento lo ordenará\r
+label.sort_with_new_tree = Ordenar con el nuevo árbol\r
+label.from_textbox = desde un área de texto\r
+label.window = Ventana\r
+label.preferences = Preferencias\r
+label.tools = Herramientas\r
+label.fetch_sequences = Recuperar secuencia(s)\r
+label.stop_vamsas_session = Parar sesión vamsas\r
+label.collect_garbage = Recolector de basura\r
+label.show_memory_usage = Mostrar uso de memoria\r
+label.show_java_console = Mostrar consola de Java\r
+label.show_jalview_news = Mostrar las noticias de Jalview\r
+label.take_snapshot = Tomar captura\r
+label.monospaced_fonts_faster_to_render = Las fuentes monoespaciadas son más rápidas de pintar\r
+label.anti_alias_fonts = Fuentes anti-alias (más lentas de pintar)\r
+label.monospaced_font= Monoespaciadas\r
+label.quality = Calidad\r
+label.maximize_window = Maximizar ventana\r
+label.conservation = Conservación\r
+label.consensus = Consenso\r
+label.histogram = Histograma\r
+label.logo = Logo\r
+label.non_positional_features = Características no posicionales\r
+label.database_references = Referencias a base de datos\r
+label.share_selection_across_views = Compartir la selección en todas las vistas\r
+label.scroll_highlighted_regions = Desplazarse hasta las regiones resaltadas\r
+label.gap_symbol = Símbolo del hueco\r
+label.alignment_colour = Color del alineamiento\r
+label.address = Dirección\r
+label.port = Puerto\r
+label.default_browser_unix = Navegador por defecto (Unix)\r
+label.send_usage_statistics = Enviar estadísticas de uso\r
+label.check_for_questionnaires = Comprobar los cuestionarios\r
+label.check_for_latest_version = Comprobar la última versión\r
+label.url_linkfrom_sequence_id = URL del enlace del ID de la secuencia\r
+label.use_proxy_server = Utilizar un servidor proxy\r
+label.eps_rendering_style = Estilo de visualización EPS\r
+label.append_start_end = Añadir /inicio-fin (/15-380)\r
+label.full_sequence_id = ID de la secuencia completo\r
+label.smooth_font = Fuente alargada\r
+label.autocalculate_consensus = Autocalcular consenso\r
+label.pad_gaps = Rellenar huecos\r
+label.pad_gaps_when_editing = Rellenar huecos al editar\r
+label.automatically_set_id_width = Establecer automáticamente al anchura del ID\r
+label.figure_id_column_width = Anchura de la columna del ID de la Figura\r
+label.use_modeller_output = Utilizar la salidad del Modeller\r
+label.wrap_alignment = Envolver alineamiento\r
+label.right_align_ids = Alinear IDs a la derecha\r
+label.sequence_name_italics = Nombre de la secuencia en cursiva\r
+label.open_overview = Abrir resumen\r
+label.default_colour_scheme_for_alignment = Esquema cromático por defecto para el alineamiento\r
+label.annotation_shading_default = Sombreado por defecto de la anotación\r
+label.default_minimum_colour_annotation_shading = Por mínimo por defecto para el sombreado de la anotación\r
+label.default_maximum_colour_annotation_shading = Por máximo por defecto para el sombreado de la anotación\r
+label.visual = Visual\r
+label.connections = Conexiones\r
+label.output = Salida\r
+label.editing = Edición\r
+label.das_settings = Configuración DAS\r
+label.web_services = Servicios web\r
+label.right_click_to_edit_currently_selected_parameter = Haga clic en el botón derecho para editar el parámetro seleccionado actualmente.\r
+label.let_jmol_manage_structure_colours = Permitir que Jmol gestione la estructuras cromáticas\r
+label.marks_leaves_tree_not_associated_with_sequence = Marcar las hojas del árbol que no están asociadas a una secuencia\r
+label.index_web_services_menu_by_host_site = Indizar los servicios web en el menú por el host que los aloja\r
+label.option_want_informed_web_service_URL_cannot_be_accessed_jalview_when_starts_up = Marque esta opción si desea ser informado<br>cuando no se pueda acceder a la URL de un servicio web<br>al arrancar Jalview.\r
+label.new_service_url = Nueva URL del servicio\r
+label.edit_service_url = Editar la URL del servicio\r
+label.delete_service_url = Borrar la URL del servicio\r
+label.details = Detalles\r
+label.options = Opciones\r
+label.parameters = Paramétros\r
+label.available_das_sources = Fuentes DAS disponibles\r
+label.full_details = Detalles completos\r
+label.authority = Autoridad\r
+label.type = Tipo\r
+label.proxy_server = Servidor proxy\r
+label.file_output = Fichero de salida\r
+label.select_input_type = Seleccionar el tipo de entrada\r
+label.set_options_for_type = Establecer opciones para el tipo\r
+label.data_input_parameters = Datos de los parámetros de entrada\r
+label.data_returned_by_service = Datos devueltos por el servicio\r
+label.rsbs_encoded_service = Servicio RSBS codificado\r
+label.parsing_errors = Errores de parseo\r
+label.simple_bioinformatics_rest_services = Simple Bioinformatics Rest Services\r
+label.web_service_discovery_urls = URL de descubrimiento de servicios web\r
+label.input_parameter_name = Nombre del parámetro de entrada\r
+label.short_descriptive_name_for_service = Nombre corto descriptivo del servicio\r
+label.function_service_performs = Tipo de función que realiza el servicio (p.e. alineamiento, análisis, búsqueda, etc).\r
+label.brief_description_service = Descripción breve del servicio\r
+label.url_post_data_service = URL a la que enviar los datos del servicio. Incluya cualquier parámetro especial que se necesite aquí\r
+label.optional_suffix = Sufijo opcional añadido a la URL al recuperar los resultados del servicio\r
+label.preferred_gap_character = ¿Qué caracter para el hueco prefiere el servicio?\r
+label.gap_character = Carácter para hueco\r
+label.move_return_type_up_order= Mover el tipo de returno hacia arriba en el orden\r
+label.move_return_type_down_order= Mover el tipo de returno hacia abajo en el orden\r
+label.update_user_parameter_set = Actualizar el conjunto de parámetros de usuario existente\r
+label.delete_user_parameter_set = Borrar el conjunto de parámetros de usuario existente\r
+label.create_user_parameter_set = Crear un nuevo conjunto de parámetro con la configuración actual.\r
+label.revert_changes_user_parameter_set = Deshacer todos los cambios en el conjunto de parámetros actual\r
+label.start_job_current_settings = Arrancar trabajo con la configuración actual\r
+label.cancel_job_close_dialog = Cerrar este diálogo y cancelar el trabajo\r
+label.input_output = Entrada/Salida\r
+label.cut_paste = Cortar y pegar\r
+label.adjusting_parameters_for_calculation = Ajustar los parámetros para el cálculo existente\r
+label.2d_rna_structure_line = 2D RNA {0}\r
+label.2d_rna_sequence_name = 2D RNA - {0}\r
+label.edit_name_and_description_current_group = Editar el nombre y la descripción del grupo actual.\r
+label.view_structure_for = Visualizar la estructura para {0}\r
+label.view_all_structures = Visualizar todas las {0} estructuras.\r
+label.view_all_representative_structures = Visualizar todas las {0} estructuras representativas.\r
+label.open_new_jmol_view_with_all_representative_structures_associated_current_selection_superimpose_using_alignment = Abrir una nueva vista de Jmol con todas las estructuras representativas\nasociadas con la selecci\u00F3n actual\nsuperpuesta con el alineamiento actual.\r
+label.associate_structure_with_sequence = Asociar estructura con la secuencia\r
+label.from_file = desde fichero\r
+label.enter_pdb_id = Introducir PDB Id\r
+label.discover_pdb_ids = Buscar PDB ids\r
+label.text_colour = Color del texto\r
+label.structure = Estructura\r
+label.view_structure = Visualizar estructura\r
+label.clustalx_colours = Colores de Clustalx\r
+label.above_identity_percentage = Sobre % identidad\r
+label.create_sequence_details_report_annotation_for = Anotación para {0}\r
+label.sequece_details_for = Detalles de la secuencia para {0}\r
+label.sequence_name = Nombre de la secuencia\r
+label.sequence_description = Descripción de la secuencia\r
+label.edit_sequence_name_description = Editar el nombre/descripción de la secuencia\r
+label.spaces_converted_to_backslashes = Los espacios se han convertido en _\r
+label.no_spaces_allowed_sequence_name = No se permiten espacios en el nombre de la secuencia\r
+label.select_outline_colour = Seleccionar el color del límite\r
+label.web_browser_not_found_unix = Unixers\: No es posible encontrar el navegador web por defecto.\nA\u00F1ada la ruta completa de su navegador en la pesta\u00F1a de Preferencias.\r
+label.web_browser_not_found = No se encuentra el navegador web\r
+label.select_pdb_file_for = Seleccione un fichero PDB para {0}\r
+label.html = HTML\r
+label.wrap = Envolver\r
+label.show_database_refs = Mostrar las referencias en base de datos\r
+label.show_non_positional_features = Mostrar las características no posicionales\r
+label.save_png_image = Guardar como imagen PNG\r
+label.load_tree_for_sequence_set = Cargar un árbol para este conjunto de secuencias\r
+label.export_image = Exportar imagen\r
+label.vamsas_store = Almacén VAMSAS\r
+label.translate_cDNA = Traducir cDNA\r
+label.extract_scores = Extraer puntuaciones\r
+label.get_cross_refs = Obtener referencias cruzadas\r
+label.sort_alignment_new_tree = Alinear el alineamiento con el nuevo árbol\r
+label.add_sequences = Añadir secuencias\r
+label.new_window = Nueva ventana\r
+label.refresh_available_sources = Refrescar las fuentes disponibles\r
+label.use_registry = Utilizar el registro\r
+label.add_local_source = Añadir fuente local\r
+label.set_as_default = Establecer por defecto\r
+label.show_labels = Mostrar etiquetas\r
+label.background_colour = Color de fondo\r
+label.associate_nodes_with = Asociar nodos con\r
+label.jalview_pca_calculation = Cálculo del PCA por Jalview\r
+label.link_name = Nombre del enalce\r
+label.pdb_file = Fichero PDB\r
+label.colour_with_jmol = Colorear con Jmol\r
+label.align_structures = Alinear estructuras\r
+label.jmol = Jmol\r
+label.sort_alignment_by_tree = Ordenar alineamiento por árbol\r
+label.mark_unlinked_leaves = Marcar las hojas como no enlazadas\r
+label.associate_leaves_with = Asociar hojas con\r
+label.save_colour_scheme_with_unique_name_added_to_colour_menu = Guarde el esquema cromáticos con un nombre único y se añadirá al menú de colores\r
+label.case_sensitive = Sensible a mayúsculas\r
+label.lower_case_colour = Color para las minúsculas\r
+label.index_by_host = Indizar por host\r
+label.index_by_type = Indizar por tipo\r
+label.enable_jabaws_services = Habilitar servicios JABAWS\r
+label.display_warnings = Mostrar advertencias\r
+label.move_url_up = Mover la URL hacia arriba\r
+label.move_url_down = Mover la URL hacia abajo\r
+label.add_sbrs_definition = Añadir una definición SBRS \r
+label.edit_sbrs_definition = Editar una definición SBRS \r
+label.delete_sbrs_definition = Borrar una definición SBRS \r
+label.your_sequences_have_been_verified = Sus secuencias has sido verificadas en una base de datos de secuencias conocidas. Algunos de sus ID se han alterado y\n, probablemente, el residuo de inicio/fin se haya actualizado.\nGuarde su alineamiento para mantener el ID actualizado.\n\n \r
+label.sequence_names_updated = Nombres de secuencia actualizados\r
+label.dbref_search_completed = Búsqueda de DBRef terminada\r
+label.show_all_chains = Mostrar todas las cadenas\r
+label.fetch_all_param = Recuperar todas {0}\r
+label.paste_new_window = Pegar en una nueva ventana\r
+label.settings_for_param = Configuración para {0}\r
+label.view_params = Visualizar {0}\r
+label.select_all_views = Seleccionar todas las vistas\r
+label.align_sequences_to_existing_alignment = Alinear las secuencias con el alineamiento existente\r
+label.realign_with_params = Realinear con {0}\r
+label.calcname_with_default_settings = {0} por defecto\r
+label.action_with_default_settings = {0} con la configuración por defecto\r
+label.edit_settings_and_run = Editar la configuración y ejecutar...\r
+label.view_and_change_parameters_before_alignment = Ver y cambiar los parámetros antes del alineamiento\r
+label.run_with_preset_params = Ejecutar {0} con preconfiguración\r
+label.view_and_change_parameters_before_running_calculation = Ver y cambiar los parámetros antes de lanzar el cálculo\r
+label.view_documentation = Ver documentación\r
+label.select_return_type = Seleccionar el tipo de retorno\r
+label.translation_of_params = Traducción de {0}\r
+label.features_for_params = Características de - {0}\r
+label.annotations_for_params = Anotaciones de - {0}\r
+label.generating_features_for_params = Generando características de - {0}\r
+label.generating_annotations_for_params = Generando anotaciones de - {0}\r
+label.varna_params = VARNA - {0}\r
+label.sequence_feature_settings = Configuración de las características de la secuencia\r
+label.pairwise_aligned_sequences = Secuencias alineadas a pares\r
+label.original_data_for_params = Datos originales de {0}\r
+label.points_for_params = Puntos de {0}\r
+label.transformed_points_for_params = Puntos transformados de {0}\r
+label.graduated_color_for_params = Color graduado para la característica de {0}\r
+label.select_backgroud_colour = Seleccionar color de fondo\r
+label.invalid_font = Fuente no válida\r
+label.separate_multiple_accession_ids = Separar los accession id con un punto y coma ";"\r
+label.replace_commas_semicolons = Cambiar comas por puntos y comas\r
+label.parsing_failed_syntax_errors_shown_below_param = Parseo erróneo. A continuación, se muestras los errores de sintaxis {0}\r
+label.parsing_failed_unrecoverable_exception_thrown_param = \nParseo err\u00F3neo. Se ha lanzado una excepci\u00F3n fatal\:\n {0}\r
+label.example_query_param = Consulta de ejemplo: {0}\r
+label.enter_value_increase_conservation_visibility = Introduzca un valor para incrementar la visibilidad de la conservación\r
+label.enter_percentage_identity_above_which_colour_residues = Introduza un % de identidad por encima del cual se colorearán los residuos\r
+label.wswublast_client_credits = Para mostrar las caracter\u00EDsticas de una secuencia, debe indicarse un id de Uniprot cuya secuencia se corresponda al 100 % con la introducida.\nPara mostrar estas caracter\u00EDsticas, prueba a cambar los nombre de sus secuencia con los ID que se sugieren a continuaci\u00F3n.\n\nRunning WSWUBlast at EBI.\nPlease quote Pillai S., Silventoinen V., Kallio K., Senger M., Sobhany S., Tate J., Velankar S., Golovin A., Henrick K., Rice P., Stoehr P., Lopez R.\nSOAP-based services provided by the European Bioinformatics Institute.\nNucleic Acids Res. 33(1)\:W25-W28 (2005));\r
+label.blasting_for_unidentified_sequence = Ejecutar BLAST para la secuencias sin identificar\r
+label.select_columns_containing = Seleccione las columnas que contengan\r
+label.select_columns_not_containing = Seleccione las columnas que no contengan\r
+option.trim_retrieved_seqs = Ajustar las secuencias recuperadas\r
+label.trim_retrieved_sequences = Cuando la secuencia de referencia es más larga que la secuencia con la que está trabajando, sólo se mantienen las subsecuencias relevantes.\r
+label.use_sequence_id_1 = Utilice $SEQUENCE_ID$ o $SEQUENCE_ID=/<regex>/=$\r
+label.use_sequence_id_2 = \nto para embeber el id de la secuencia en una URL\r
+label.ws_parameters_for = Parámetros para {0}\r
+label.switch_server = Cambiar servidor\r
+label.open_jabaws_web_page = Abre el página principal del servidor JABAWS en un navegador web\r
+label.choose_jabaws_server = Escoja un servidor para ejecutar este servicio\r
+label.services_at = Servicios en {0}\r
+label.rest_client_submit = {0} utilizando {1}\r
+label.fetch_retrieve_from =Recuperar de {0}\r
+label.fetch_retrieve_from_all_sources = Recuperar de todas las fuentes {0} en {1}<br>La primera es :{2} \r
+label.feature_settings_click_drag = Haga clic o arrastre los tipos de las características hacia arriba o hacia abajo para cambiar el orden de visualización.<br/>Haga doble clic para seleccionar las columnas que contienen las características del alineamiento/selección actual.<br/>Presionando Alt seleccionará las columnas exteriores a las características en lugar de las interiores<br/>Presione Shift para modificar la selección actual (en lugar de borrarla)<br/>Presione CTRL o Command/Meta para cambiar las columans externas o internas a las características<br/>\r
+label.opt_and_params_further_details = ver los detalles adicionales haciendo clic en el botón derecho\r
+label.opt_and_params_show_brief_desc_image_link = Haga clic para ver una descripción breve<br><img src="{0}"/>Haga clic en el botón derecho para obtener información adicional. \r
+label.opt_and_params_show_brief_desc = Haga clic para ver una descripción breve<br>\r
+label.adjusts_width_generated_eps_png = Ajusta la anchura del fichero EPS o PNG generado para asegurar incluso que el ID de la secuencia más larga o las etiquetas de anotación se muestran\r
+label.manually_specify_width_left_column = Especificar manualmente la anchura de la columna izquierda en las etiquetas de los ID de la secuencia y las anotaciones se mostrar en las figuras del alineamiento exportado.Esta configuraicón se ignorará si está marcada la opción 'Establecer automáticamente al anchura del ID'\r
+label.job_created_when_checked = Cuando está habilitado, se crea un trabajo para cada secuencia de la selección actual\r
+label.when_checked_job_visible_region_and_results = Cuando está habilitado, se crea un único trabajo para la región visible y los resultados de mapean en su ubicación dentro del alineamiento. En caso contrario, se creará un trabajo para cada región visible y contigua en el alineamiento o selección actual (p.e. un alineamiento múlitple).\r
+label.flat_file_representation = La representación del fichero plano de este servicio utilizando el formalismo Really Simple Bioinformatics Service\r
+label.result_of_parsing_rsbs = Resultados de parsear la representación RSBS\r
+label.user_preset = Preselección de usuario\r
+label.service_preset = Preselección del servicio\r
+label.run_with_preset = Ejecutar {0} con preselección\r
+label.view_service_doc_url = Visualizar <a href="{0}">{1}</a>\r
+label.submit_sequence = Enviar {0} {1} {2} {3} a<br/>{4}\r
+action.by_title_param = por {0}\r
+label.alignment = Alineamiento\r
+label.secondary_structure_prediction = Predicción de la estructura secundaria\r
+label.sequence_database_search = Búsqueda en base de datos de secuencias\r
+label.analysis = Análisis\r
+label.protein_disorder = Desorden en la proteína \r
+label.source_from_db_source = Fuentes de {0}\r
+label.from_msname = de '{0}'\r
+label.superpose_with = Superponer con...\r
+action.do = Hacer\r
+label.scale_label_to_column = Ajustar la etiqueta a la columna\r
+label.add_new_row = Añadir nuevo fila\r
+label.edit_label_description = Editar etiqueta/descripción\r
+label.hide_row = Ocultar esta fila\r
+label.delete_row = Borrar esta fila\r
+label.show_all_hidden_rows = Mostrar todas las filas ocultas\r
+label.export_annotation = Exportar anotación\r
+label.copy_consensus_sequence = Copiar secuencia de consenso\r
+label.helix = Hélice\r
+label.sheet = Hoja\r
+label.rna_helix = Hélice de ARN\r
+label.remove_annotation = Borrar anotación\r
+label.colour_by = Colorear por...\r
+label.muscle_multiple_protein_sequence_alignment = Alineamiento múltiple de secuencias de proteínas con Muscle\r
+label.mafft_multiple_sequence_alignment = Alineamiento múltiple de secuencias con MAFFT\r
+label.clustalw_multiple_sequence_alignment = Alineamiento múltiple de secuencias con ClustalW\r
+label.jnet_secondary_structure_prediction = Predicción de la estructura secundaria con JNet\r
+label.multiharmony = Multi-Harmony\r
+label.unable_start_web_service_analysis = No es posible iniciar el servicio web de análisis\r
+label.job_couldnt_be_started_check_input = El trabajo no puede arrancarse. Por favor, compruebe los parámetros de entrada y los mensajes de advertencia de la consola de Jalview.\r
+label.prompt_each_time = Preguntar siempre\r
+label.use_source = Fuente\r
+label.couldnt_save_project = No es posible guardar el proyecto\r
+label.error_whilst_saving_current_state_to = Error mientras se guardaba el estado a {0}\r
+label.error_whilst_loading_project_from = Error cargado el proyecto desde  {0}\r
+label.couldnt_load_project = No es posible cargar el proyecto\r
index eb214ac..b4cb80c 100755 (executable)
@@ -671,7 +671,7 @@ public class PDBViewer extends JInternalFrame implements Runnable
             jalview.bin.Cache.getProperty("LAST_DIRECTORY"));
 
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save PDB File");
+    chooser.setDialogTitle(MessageManager.getString("label.save_pdb_file"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
index 302f3b2..7f5c427 100755 (executable)
@@ -28,6 +28,7 @@ import java.awt.*;
 import jalview.analysis.AlignSeq;
 import jalview.datamodel.*;
 import jalview.io.FileParse;
+import jalview.util.MessageManager;
 
 public class PDBfile extends jalview.io.AlignFile
 {
@@ -240,7 +241,9 @@ public class PDBfile extends jalview.io.AlignFile
     } catch (OutOfMemoryError er)
     {
       System.out.println("OUT OF MEMORY LOADING PDB FILE");
-      throw new IOException("Out of memory loading PDB File");
+      throw new IOException(
+              MessageManager
+                      .getString("exception.outofmemory_loading_pdb_file"));
     } catch (NumberFormatException ex)
     {
       if (line != null)
@@ -304,6 +307,14 @@ public class PDBfile extends jalview.io.AlignFile
     ;
   }
 
+  /**
+   * matches ochains against al and populates seqs with the best match between
+   * each ochain and the set in al
+   * 
+   * @param ochains
+   * @param al
+   * @param dnaOrProtein
+   */
   private void replaceMatchingSeqsWith(ArrayList<SequenceI> ochains,
           AlignmentI al, String dnaOrProtein)
   {
index 543391e..3a3462c 100755 (executable)
@@ -7,6 +7,8 @@
 //
 package com.stevesoft.pat;
 
+import jalview.util.MessageManager;
+
 import java.util.*;
 
 /**
@@ -259,7 +261,7 @@ public abstract class Pattern
    */
   Pattern clone1(Hashtable h)
   {
-    throw new Error("No such method as clone1 for " + getClass().getName());
+    throw new Error(MessageManager.formatMessage("error.no_such_method_as_clone1_for", new String[]{getClass().getName()}));
   }
 
   Pattern clone(Hashtable h)
@@ -272,7 +274,7 @@ public abstract class Pattern
     p = clone1(h);
     if (p == null)
     {
-      throw new Error("Null from clone1!");
+      throw new Error(MessageManager.getString("error.null_from_clone1"));
     }
     h.put(this, p);
     h.put(p, p);
index 04bb0da..861c33b 100755 (executable)
@@ -7,6 +7,8 @@
 //
 package com.stevesoft.pat;
 
+import jalview.util.MessageManager;
+
 import java.io.*;
 import java.util.*;
 
@@ -775,7 +777,7 @@ public class Regex extends RegRes implements FilenameFilter
   {
     if (s == null)
     {
-      throw new NullPointerException("Null String Given to Regex.search");
+      throw new NullPointerException(MessageManager.getString("exception.null_string_given_to_regex_search"));
     }
     return _search(s, 0, s.length());
   }
@@ -784,8 +786,7 @@ public class Regex extends RegRes implements FilenameFilter
   {
     if (sl == null)
     {
-      throw new NullPointerException(
-              "Null StringLike Given to Regex.search");
+      throw new NullPointerException(MessageManager.getString("exception.null_string_like_given_to_regex_search"));
     }
     return _search(sl, 0, sl.length());
   }
@@ -794,8 +795,7 @@ public class Regex extends RegRes implements FilenameFilter
   {
     if (s == null)
     {
-      throw new NullPointerException(
-              "Null String Given to Regex.reverseSearch");
+      throw new NullPointerException(MessageManager.getString("exception.null_string_given_to_regex_reverse_search"));
     }
     return _reverseSearch(s, 0, s.length());
   }
@@ -804,8 +804,7 @@ public class Regex extends RegRes implements FilenameFilter
   {
     if (sl == null)
     {
-      throw new NullPointerException(
-              "Null StringLike Given to Regex.reverseSearch");
+      throw new NullPointerException(MessageManager.getString("exception.null_string_like_given_to_regex_reverse_search"));
     }
     return _reverseSearch(sl, 0, sl.length());
   }
@@ -822,8 +821,7 @@ public class Regex extends RegRes implements FilenameFilter
   {
     if (s == null)
     {
-      throw new NullPointerException(
-              "Null String Given to Regex.searchFrom");
+      throw new NullPointerException(MessageManager.getString("exception.null_string_like_given_to_regex_search_from"));
     }
     return _search(s, start, s.length());
   }
@@ -832,8 +830,7 @@ public class Regex extends RegRes implements FilenameFilter
   {
     if (s == null)
     {
-      throw new NullPointerException(
-              "Null String Given to Regex.searchFrom");
+        throw new NullPointerException(MessageManager.getString("exception.null_string_like_given_to_regex_search_from"));
     }
     return _search(s, start, s.length());
   }
@@ -845,8 +842,7 @@ public class Regex extends RegRes implements FilenameFilter
   {
     if (s == null)
     {
-      throw new NullPointerException(
-              "Null String Given to Regex.searchRegion");
+      throw new NullPointerException(MessageManager.getString("exception.null_string_like_given_to_regex_search_region"));
     }
     return _search(s, start, end);
   }
index 062a548..b886f6a 100755 (executable)
@@ -7,6 +7,8 @@
 //
 package com.stevesoft.pat;
 
+import jalview.util.MessageManager;
+
 import com.stevesoft.pat.wrap.*;
 
 /** Internally used class. */
@@ -178,7 +180,7 @@ public class Replacer
     lastMatchedTo = 0;
     if (rh.me == null)
     {
-      throw new NullPointerException("Replacer has null Regex pointer");
+      throw new NullPointerException(MessageManager.getString("exception.replace_null_regex_pointer"));
     }
     if (rh.me._search(s, start, end))
     {
index d770f08..84a3a46 100755 (executable)
@@ -7,6 +7,8 @@
 //
 package com.stevesoft.pat;
 
+import jalview.util.MessageManager;
+
 import com.stevesoft.pat.wrap.*;
 
 /**
@@ -149,7 +151,7 @@ public class Transformer
     Regex r = Regex.perlCode(rs);
     if (r == null)
     {
-      throw new NullPointerException("bad pattern to Regex.perlCode: " + rs);
+      throw new NullPointerException(MessageManager.formatMessage("exception.bad_pattern_to_regex_perl_code", new String[]{rs}));
     }
     add(r);
   }
index b4d38dc..f5b61ab 100755 (executable)
@@ -7,6 +7,8 @@
 //
 package com.stevesoft.pat.wrap;
 
+import jalview.util.MessageManager;
+
 import java.io.*;
 
 import com.stevesoft.pat.*;
@@ -84,13 +86,16 @@ public class RandomAccessFileWrap implements StringLike
     {
     }
 
-    throw new ArrayIndexOutOfBoundsException("Out of bounds for file:"
-            + " i=" + i + ", Final Buffer: i0=" + i0 + " iend=" + iend);
+    throw new ArrayIndexOutOfBoundsException(MessageManager.formatMessage("exception.out_of_bounds_for_file", new String[]{
+               Integer.valueOf(i).toString(),
+               Integer.valueOf(i0).toString(),
+               Integer.valueOf(iend).toString()
+    }));
   }
 
   public String toString()
   {
-    throw new Error("Not implemented");
+    throw new Error(MessageManager.getString("error.not_implemented"));
   }
 
   public int length()
index 6bd3af0..3473d4c 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package ext.vamsas;
 
+import jalview.util.MessageManager;
+
 public class IRegistryServiceLocator extends org.apache.axis.client.Service
         implements ext.vamsas.IRegistryService
 {
@@ -109,10 +111,7 @@ public class IRegistryServiceLocator extends org.apache.axis.client.Service
     {
       throw new javax.xml.rpc.ServiceException(t);
     }
-    throw new javax.xml.rpc.ServiceException(
-            "There is no stub implementation for the interface:  "
-                    + (serviceEndpointInterface == null ? "null"
-                            : serviceEndpointInterface.getName()));
+    throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.no_stub_implementation_for_interface", new String[]{(serviceEndpointInterface == null ? "null": serviceEndpointInterface.getName())}));
   }
 
   /**
@@ -169,8 +168,7 @@ public class IRegistryServiceLocator extends org.apache.axis.client.Service
     }
     else
     { // Unknown Port Name
-      throw new javax.xml.rpc.ServiceException(
-              " Cannot set Endpoint Address for Unknown Port" + portName);
+      throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.cannot_set_endpoint_address_unknown_port", new String[]{portName}));
     }
   }
 
index 46566b9..79e9636 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package ext.vamsas;
 
+import jalview.util.MessageManager;
+
 public class JpredServiceLocator extends org.apache.axis.client.Service
         implements ext.vamsas.JpredService
 {
@@ -107,10 +109,7 @@ public class JpredServiceLocator extends org.apache.axis.client.Service
     {
       throw new javax.xml.rpc.ServiceException(t);
     }
-    throw new javax.xml.rpc.ServiceException(
-            "There is no stub implementation for the interface:  "
-                    + (serviceEndpointInterface == null ? "null"
-                            : serviceEndpointInterface.getName()));
+    throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.no_stub_implementation_for_interface", new String[]{(serviceEndpointInterface == null ? "null": serviceEndpointInterface.getName())}));
   }
 
   /**
@@ -167,8 +166,7 @@ public class JpredServiceLocator extends org.apache.axis.client.Service
     }
     else
     { // Unknown Port Name
-      throw new javax.xml.rpc.ServiceException(
-              " Cannot set Endpoint Address for Unknown Port" + portName);
+      throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.cannot_set_endpoint_address_unknown_port", new String[]{portName}));
     }
   }
 
index a9ca1ed..9a580f8 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package ext.vamsas;
 
+import jalview.util.MessageManager;
+
 public class MuscleWSServiceLocator extends org.apache.axis.client.Service
         implements ext.vamsas.MuscleWSService
 {
@@ -115,10 +117,7 @@ public class MuscleWSServiceLocator extends org.apache.axis.client.Service
       throw new javax.xml.rpc.ServiceException(t);
     }
 
-    throw new javax.xml.rpc.ServiceException(
-            "There is no stub implementation for the interface:  "
-                    + ((serviceEndpointInterface == null) ? "null"
-                            : serviceEndpointInterface.getName()));
+    throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.no_stub_implementation_for_interface", new String[]{(serviceEndpointInterface == null ? "null": serviceEndpointInterface.getName())}));
   }
 
   /**
@@ -177,8 +176,7 @@ public class MuscleWSServiceLocator extends org.apache.axis.client.Service
     }
     else
     { // Unknown Port Name
-      throw new javax.xml.rpc.ServiceException(
-              " Cannot set Endpoint Address for Unknown Port" + portName);
+      throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.cannot_set_endpoint_address_unknown_port", new String[]{portName}));
     }
   }
 
index cfe943c..75f46a3 100644 (file)
@@ -20,6 +20,8 @@
  */
 package ext.vamsas;
 
+import jalview.util.MessageManager;
+
 public class SeqSearchServiceLocator extends org.apache.axis.client.Service
         implements ext.vamsas.SeqSearchServiceService
 {
@@ -109,10 +111,7 @@ public class SeqSearchServiceLocator extends org.apache.axis.client.Service
     {
       throw new javax.xml.rpc.ServiceException(t);
     }
-    throw new javax.xml.rpc.ServiceException(
-            "There is no stub implementation for the interface:  "
-                    + (serviceEndpointInterface == null ? "null"
-                            : serviceEndpointInterface.getName()));
+    throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.no_stub_implementation_for_interface", new String[]{(serviceEndpointInterface == null ? "null": serviceEndpointInterface.getName())}));
   }
 
   /**
@@ -169,8 +168,7 @@ public class SeqSearchServiceLocator extends org.apache.axis.client.Service
     }
     else
     { // Unknown Port Name
-      throw new javax.xml.rpc.ServiceException(
-              " Cannot set Endpoint Address for Unknown Port" + portName);
+      throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.cannot_set_endpoint_address_unknown_port", new String[]{portName}));
     }
   }
 
index ab6fae8..4460985 100755 (executable)
@@ -410,8 +410,7 @@ public class AlignSeq
     else
     {
       output.append("Wrong type = dna or pep only");
-      throw new Error("Unknown Type " + type2
-              + " - dna or pep are the only allowed values.");
+      throw new Error(MessageManager.formatMessage("error.unknown_type_dna_or_pep", new String[]{type2}));
     }
   }
 
index a993e26..b7cfbbd 100755 (executable)
@@ -757,8 +757,7 @@ public class AlignmentSorter
     if (method != FEATURE_SCORE && method != FEATURE_LABEL
             && method != FEATURE_DENSITY)
     {
-      throw new Error(
-              "Implementation Error - sortByFeature method must be one of FEATURE_SCORE, FEATURE_LABEL or FEATURE_DENSITY.");
+      throw new Error(MessageManager.getString("error.implementation_error_sortbyfeature"));
     }
     boolean ignoreScore = method != FEATURE_SCORE;
     StringBuffer scoreLabel = new StringBuffer();
@@ -938,7 +937,7 @@ public class AlignmentSorter
     {
       if (method == FEATURE_LABEL)
       {
-        throw new Error("Not yet implemented.");
+        throw new Error(MessageManager.getString("error.not_yet_implemented"));
       }
     }
     if (lastSortByFeatureScore == null
index 4c05ece..e4a0d76 100644 (file)
@@ -35,6 +35,7 @@ import java.util.Vector;
 
 import jalview.analysis.SecStrConsensus.SimpleBP;
 import jalview.datamodel.SequenceFeature;
+import jalview.util.MessageManager;
 
 public class Rna
 {
@@ -85,9 +86,7 @@ public class Rna
   {
     if (!isClosingParenthesis(closingParenthesis))
     {
-      throw new WUSSParseException(
-              "Querying matching opening parenthesis for non-closing parenthesis character "
-                      + closingParenthesis, -1);
+      throw new WUSSParseException(MessageManager.formatMessage("exception.querying_matching_opening_parenthesis_for_non_closing_parenthesis", new String[]{new StringBuffer(closingParenthesis).toString()}), -1);
     }
 
     return closingToOpening.get(closingParenthesis);
@@ -132,16 +131,14 @@ public class Rna
 
         if (!stacks.containsKey(opening))
         {
-          throw new WUSSParseException(
-                  "Mismatched (unseen) closing character " + base, i);
+          throw new WUSSParseException(MessageManager.formatMessage("exception.mismatched_unseen_closing_char", new String[]{new StringBuffer(base).toString()}), i);
         }
 
         Stack<Integer> stack = stacks.get(opening);
         if (stack.isEmpty())
         {
           // error whilst parsing i'th position. pass back
-          throw new WUSSParseException("Mismatched closing character "
-                  + base, i);
+          throw new WUSSParseException(MessageManager.formatMessage("exception.mismatched_closing_char", new String[]{new StringBuffer(base).toString()}), i);
         }
         int temp = stack.pop();
 
@@ -154,8 +151,7 @@ public class Rna
       Stack<Integer> stack = stacks.get(opening);
       if (!stack.empty())
       {
-        throw new WUSSParseException("Mismatched opening character "
-                + opening + " at " + stack.pop(), i);
+        throw new WUSSParseException(MessageManager.formatMessage("exception.mismatched_opening_char", new String[]{new StringBuffer(opening).toString(),Integer.valueOf(stack.pop()).toString()}), i);
       }
     }
     return pairs;
index 58c7703..eba1200 100644 (file)
@@ -559,7 +559,7 @@ public class APopupMenu extends java.awt.PopupMenu implements
 
         if (dialog.accept)
         {
-          EditCommand editCommand = new EditCommand("Edit Sequences",
+          EditCommand editCommand = new EditCommand(MessageManager.getString("label.edit_sequences"),
                   EditCommand.REPLACE, dialog.getName().replace(' ',
                           ap.av.getGapCharacter()),
                   sg.getSequencesAsArray(ap.av.getHiddenRepSequences()),
@@ -836,34 +836,34 @@ public class APopupMenu extends java.awt.PopupMenu implements
     colourMenu.add(abovePIDColour);
     colourMenu.add(conservationMenuItem);
 
-    noColourmenuItem.setLabel("None");
+    noColourmenuItem.setLabel(MessageManager.getString("label.none"));
     noColourmenuItem.addActionListener(this);
 
-    clustalColour.setLabel("Clustalx colours");
+    clustalColour.setLabel(MessageManager.getString("label.clustalx_colours"));
     clustalColour.addActionListener(this);
-    zappoColour.setLabel("Zappo");
+    zappoColour.setLabel(MessageManager.getString("label.zappo"));
     zappoColour.addActionListener(this);
-    taylorColour.setLabel("Taylor");
+    taylorColour.setLabel(MessageManager.getString("label.taylor"));
     taylorColour.addActionListener(this);
-    hydrophobicityColour.setLabel("Hydrophobicity");
+    hydrophobicityColour.setLabel(MessageManager.getString("label.hydrophobicity"));
     hydrophobicityColour.addActionListener(this);
-    helixColour.setLabel("Helix propensity");
+    helixColour.setLabel(MessageManager.getString("label.helix_propensity"));
     helixColour.addActionListener(this);
-    strandColour.setLabel("Strand propensity");
+    strandColour.setLabel(MessageManager.getString("label.strand_propensity"));
     strandColour.addActionListener(this);
-    turnColour.setLabel("Turn propensity");
+    turnColour.setLabel(MessageManager.getString("label.turn_propensity"));
     turnColour.addActionListener(this);
-    buriedColour.setLabel("Buried Index");
+    buriedColour.setLabel(MessageManager.getString("label.buried_index"));
     buriedColour.addActionListener(this);
-    abovePIDColour.setLabel("Above % Identity");
+    abovePIDColour.setLabel(MessageManager.getString("label.above_identity_percentage"));
 
-    userDefinedColour.setLabel("User Defined");
+    userDefinedColour.setLabel(MessageManager.getString("action.user_defined"));
     userDefinedColour.addActionListener(this);
-    PIDColour.setLabel("Percentage Identity");
+    PIDColour.setLabel(MessageManager.getString("action.percentage_identity"));
     PIDColour.addActionListener(this);
     BLOSUM62Colour.setLabel("BLOSUM62");
     BLOSUM62Colour.addActionListener(this);
-    conservationMenuItem.setLabel("Conservation");
+    conservationMenuItem.setLabel(MessageManager.getString("label.conservation"));
 
     editMenu.add(copy);
     copy.addActionListener(this);
index cc1703c..f267858 100644 (file)
@@ -1763,14 +1763,14 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
 
       if (newAlignment)
       {
-        String newtitle = new String("Copied sequences");
-        if (getTitle().startsWith("Copied sequences"))
+        String newtitle = MessageManager.getString("label.copied_sequences");
+        if (getTitle().startsWith(MessageManager.getString("label.copied_sequences")))
         {
           newtitle = getTitle();
         }
         else
         {
-          newtitle = newtitle.concat("- from " + getTitle());
+          newtitle = newtitle.concat(MessageManager.formatMessage("label.from_msname", new String[]{getTitle()}));
         }
         AlignFrame af = new AlignFrame(new Alignment(newSeqs),
                 viewport.applet, newtitle, false);
@@ -1805,7 +1805,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     }
 
     // !newAlignment
-    addHistoryItem(new EditCommand("Add sequences", EditCommand.PASTE,
+    addHistoryItem(new EditCommand(MessageManager.getString("label.add_sequences"), EditCommand.PASTE,
             seqs, 0, viewport.getAlignment().getWidth(),
             viewport.getAlignment()));
 
@@ -1855,7 +1855,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     /*
      * //ADD HISTORY ITEM
      */
-    addHistoryItem(new EditCommand("Cut Sequences", EditCommand.CUT, cut,
+    addHistoryItem(new EditCommand(MessageManager.getString("label.cut_sequences"), EditCommand.CUT, cut,
             sg.getStartRes(), sg.getEndRes() - sg.getStartRes() + 1,
             viewport.getAlignment()));
 
@@ -2780,10 +2780,10 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
           MessageManager.getString("label.load_features_annotations"));
 
   MenuItem outputFeatures = new MenuItem(
-          MessageManager.getString("label.export_features"));
+          MessageManager.getString("label.export_features").concat("..."));
 
   MenuItem outputAnnotations = new MenuItem(
-          MessageManager.getString("label.export_annotations"));
+          MessageManager.getString("label.export_annotations").concat("..."));
 
   MenuItem closeMenuItem = new MenuItem(
           MessageManager.getString("action.close"));
@@ -3043,7 +3043,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener,
     sortGroupMenuItem.setLabel(MessageManager.getString("action.by_group"));
     sortGroupMenuItem.addActionListener(this);
     removeRedundancyMenuItem.setLabel(MessageManager
-            .getString("action.remove_redundancy"));
+            .getString("action.remove_redundancy").concat("..."));
     removeRedundancyMenuItem.addActionListener(this);
     pairwiseAlignmentMenuItem.setLabel(MessageManager
             .getString("action.pairwise_alignment"));
index f85a073..c7b7c6c 100644 (file)
@@ -137,8 +137,7 @@ public class AnnotationColourChooser extends Panel implements
         threshold.select(1);
         break;
       default:
-        throw new Error(
-                "Implementation error: don't know about threshold setting for current AnnotationColourGradient.");
+        throw new Error(MessageManager.getString("error.implementation_error_dont_know_thereshold_annotationcolourgradient"));
       }
       thresholdIsMin.setState(acg.thresholdIsMinMax);
       thresholdValue.setText("" + acg.getAnnotationThreshold());
index bf82bca..42fbd70 100644 (file)
@@ -139,7 +139,7 @@ public class AppletJmol extends EmbmenuFrame implements
           String[][] boundchains, boolean align, AlignmentPanel ap,
           String protocol)
   {
-    throw new Error("Not yet implemented.");
+    throw new Error(MessageManager.getString("error.not_yet_implemented"));
   }
 
   public AppletJmol(PDBEntry pdbentry, SequenceI[] seq, String[] chains,
@@ -315,8 +315,7 @@ public class AppletJmol extends EmbmenuFrame implements
           }
           if (freader == null)
           {
-            throw new Exception(
-                    "Invalid datasource. Could not obtain Reader.");
+            throw new Exception(MessageManager.getString("exception.invalid_datasource_couldnt_obtain_reader"));
           }
           jmb.viewer.openReader(pdbentry.getFile(), pdbentry.getId(),
                   freader);
index 6c0d3a9..c527308 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.appletgui;
 
+import jalview.util.MessageManager;
+
 import java.awt.BorderLayout;
 import java.awt.Color;
 import java.awt.FlowLayout;
@@ -195,8 +197,7 @@ public class EmbmenuFrame extends Frame implements MouseListener
   {
     if (embeddedPopup == null)
     {
-      throw new Error(
-              "Implementation error - embeddedPopup must be non-null");
+      throw new Error(MessageManager.getString("error.implementation_error_embeddedpopup_not_null"));
     }
     if (overrideFonts)
     {
index aef8e31..29c3ac5 100644 (file)
@@ -151,7 +151,7 @@ public class FeatureRenderer implements jalview.api.FeatureRenderer
       }
       else
       {
-        throw new Error("Invalid color for MyCheckBox");
+        throw new Error(MessageManager.getString("error.invalid_colour_for_mycheckbox"));
       }
       if (col != null)
       {
@@ -353,8 +353,8 @@ public class FeatureRenderer implements jalview.api.FeatureRenderer
       }
     }
 
-    String title = newFeatures ? "Create New Sequence Feature(s)"
-            : "Amend/Delete Features for " + sequences[0].getName();
+    String title = newFeatures ? MessageManager.getString("label.create_new_sequence_features")
+            : MessageManager.formatMessage("label.amend_delete_features", new String[]{sequences[0].getName()});
 
     final JVDialog dialog = new JVDialog(ap.alignFrame, title, true, 385,
             240);
@@ -901,8 +901,7 @@ public class FeatureRenderer implements jalview.api.FeatureRenderer
         return ((GraduatedColor) fc).getMaxColor();
       }
     }
-    throw new Error("Implementation Error: Unrecognised render object "
-            + fc.getClass() + " for features of type " + featureType);
+    throw new Error(MessageManager.formatMessage("error.implementation_error_unrecognised_render_object_for_features_type", new String[]{fc.getClass().getCanonicalName(),featureType}));
   }
 
   /**
index f6e7772..cd11a35 100755 (executable)
@@ -592,8 +592,7 @@ public class FeatureSettings extends Panel implements ItemListener,
     }
     else
     {
-      throw new Error(
-              "Implementation error: Unsupported feature colour object.");
+      throw new Error(MessageManager.getString("error.implementation_error_unsupported_feature_colour_object"));
     }
     refreshTable();
   }
@@ -689,7 +688,7 @@ public class FeatureSettings extends Panel implements ItemListener,
       }
       else
       {
-        throw new Error("Invalid color for MyCheckBox");
+        throw new Error(MessageManager.getString("error.invalid_colour_for_mycheckbox"));
       }
       if (col != null)
       {
index f5e403f..216f45d 100644 (file)
@@ -196,7 +196,7 @@ public class RedundancyPanel extends SliderPanel implements Runnable,
         }
       }
 
-      EditCommand cut = new EditCommand("Remove Redundancy",
+      EditCommand cut = new EditCommand(MessageManager.getString("action.remove_redundancy"),
               EditCommand.CUT, deleted, 0, width, ap.av.getAlignment());
       AlignmentI alignment = ap.av.getAlignment();
       for (int i = 0; i < del.size(); i++)
index 5ba22b6..de4d979 100644 (file)
@@ -31,6 +31,7 @@ import jalview.schemes.*;
 import jalview.structure.SelectionSource;
 import jalview.structure.SequenceListener;
 import jalview.structure.StructureSelectionManager;
+import jalview.util.MessageManager;
 
 public class SeqPanel extends Panel implements MouseMotionListener,
         MouseListener, SequenceListener
@@ -945,15 +946,15 @@ public class SeqPanel extends Panel implements MouseMotionListener,
     StringBuffer message = new StringBuffer();
     if (groupEditing)
     {
-      message.append("Edit group:");
+      message.append(MessageManager.getString("action.edit_group")).append(":");
       if (editCommand == null)
       {
-        editCommand = new EditCommand("Edit Group");
+        editCommand = new EditCommand(MessageManager.getString("action.edit_group"));
       }
     }
     else
     {
-      message.append("Edit sequence: " + seq.getName());
+      message.append(MessageManager.getString("label.edit_sequence")).append(" " + seq.getName());
       String label = seq.getName();
       if (label.length() > 10)
       {
@@ -961,7 +962,7 @@ public class SeqPanel extends Panel implements MouseMotionListener,
       }
       if (editCommand == null)
       {
-        editCommand = new EditCommand("Edit " + label);
+        editCommand = new EditCommand(MessageManager.formatMessage("label.edit_params", new String[]{label}));
       }
     }
 
index 14fab4e..220a7fb 100644 (file)
@@ -59,8 +59,7 @@ public class SliderPanel extends Panel implements ActionListener,
       sp.cs = cs;
     }
 
-    conservationSlider.setTitle("Conservation Colour Increment  (" + source
-            + ")");
+    conservationSlider.setTitle(MessageManager.formatMessage("label.conservation_colour_increment", new String[]{source}));
     if (ap.av.getAlignment().getGroups() != null)
     {
       sp.setAllGroupsCheckEnabled(true);
@@ -114,7 +113,7 @@ public class SliderPanel extends Panel implements ActionListener,
       pid = (SliderPanel) PIDSlider.getComponent(0);
       pid.cs = cs;
     }
-    PIDSlider.setTitle("Percentage Identity Threshold (" + source + ")");
+    PIDSlider.setTitle(MessageManager.formatMessage("label.percentage_identity_thereshold", new String[]{source}));
 
     if (ap.av.getAlignment().getGroups() != null)
     {
index 0b18688..afa6419 100644 (file)
@@ -187,7 +187,7 @@ public class UserDefinedColours extends Panel implements ActionListener,
     setTargetColour(colour);
 
     okcancelPanel.setBounds(new Rectangle(0, 113, 400, 35));
-    frame.setTitle("User Defined Colours - " + label);
+    frame.setTitle(MessageManager.getString("label.user_defined_colours") + " - " + label);
     frame.setSize(420, 200);
   }
 
@@ -206,7 +206,7 @@ public class UserDefinedColours extends Panel implements ActionListener,
       // // not 1.1 compatible!
       // dialog = new Dialog(((JVDialog)alignframe), title, true);
       // } else {
-      throw new Error("Unsupported owner for User Colour scheme dialog.");
+      throw new Error(MessageManager.getString("label.error_unsupported_owwner_user_colour_scheme"));
     }
 
     dialog.add(this);
index b6d6d3f..046d132 100755 (executable)
@@ -44,6 +44,7 @@ import java.util.*;
 import javax.swing.*;
 
 import jalview.gui.*;
+import jalview.util.MessageManager;
 import jalview.util.Platform;
 
 /**
@@ -340,7 +341,7 @@ public class Jalview
     {
       if (!headless)
       {
-        desktop.setProgressBar("Processing commandline arguments...",
+        desktop.setProgressBar(MessageManager.getString("status.processing_commandline_args"),
                 progress = System.currentTimeMillis());
       }
       System.out.println("Opening file: " + file);
@@ -1058,7 +1059,7 @@ class FeatureFetcher
           running++;
         }
 
-        af.setProgressBar("DAS features being retrieved...", id);
+        af.setProgressBar(MessageManager.getString("status.das_features_being_retrived"), id);
         af.featureSettings_actionPerformed(null);
         af.featureSettings.fetchDasFeatures(dasSources, true);
         af.setProgressBar(null, id);
index 4e02984..ef1e16e 100644 (file)
@@ -1392,8 +1392,7 @@ public class JalviewLite extends Applet implements
       }
       else
       {
-        throw new Error(
-                "Invalid separator parameter - must be non-zero length");
+        throw new Error(MessageManager.getString("error.invalid_separator_parameter"));
       }
     }
     int r = 255;
index d1f28c0..463312f 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -156,10 +158,11 @@ public class Annotation implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationElementList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "getAnnotationElement: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._annotationElementList.size() - 1) + "]");
+      throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getAnnotationElement",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._annotationElementList.size() - 1)).toString()
+      }));
     }
 
     return (jalview.binding.AnnotationElement) _annotationElementList
@@ -365,10 +368,11 @@ public class Annotation implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationElementList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "setAnnotationElement: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._annotationElementList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setAnnotationElement",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._annotationElementList.size() - 1)).toString()
+        }));
     }
 
     this._annotationElementList.set(index, vAnnotationElement);
index 0564134..5cf43eb 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -110,9 +112,11 @@ public class FeatureSettings implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._settingList.size())
     {
-      throw new IndexOutOfBoundsException("getSetting: Index value '"
-              + index + "' not in range [0.."
-              + (this._settingList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getSetting",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._settingList.size() - 1)).toString()
+          }));         
     }
 
     return (jalview.binding.Setting) _settingList.get(index);
@@ -243,9 +247,11 @@ public class FeatureSettings implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._settingList.size())
     {
-      throw new IndexOutOfBoundsException("setSetting: Index value '"
-              + index + "' not in range [0.."
-              + (this._settingList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setSetting",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._settingList.size() - 1)).toString()
+        }));           
     }
 
     this._settingList.set(index, vSetting);
index 4a853ef..d2db3e8 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -345,8 +347,11 @@ public class JGroup implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._seqList.size())
     {
-      throw new IndexOutOfBoundsException("getSeq: Index value '" + index
-              + "' not in range [0.." + (this._seqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getSeq",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._seqList.size() - 1)).toString()
+        })); 
     }
 
     return ((java.lang.Integer) _seqList.get(index)).intValue();
@@ -704,8 +709,11 @@ public class JGroup implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._seqList.size())
     {
-      throw new IndexOutOfBoundsException("setSeq: Index value '" + index
-              + "' not in range [0.." + (this._seqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setSeq",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._seqList.size() - 1)).toString()
+          })); 
     }
 
     this._seqList.set(index, new java.lang.Integer(vSeq));
index 7b76f8a..7e2b7b1 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -242,9 +244,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._featuresList.size())
     {
-      throw new IndexOutOfBoundsException("getFeatures: Index value '"
-              + index + "' not in range [0.."
-              + (this._featuresList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getFeatures",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._featuresList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.binding.Features) _featuresList.get(index);
@@ -299,9 +303,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._pdbidsList.size())
     {
-      throw new IndexOutOfBoundsException("getPdbids: Index value '"
-              + index + "' not in range [0.."
-              + (this._pdbidsList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getPdbids",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._pdbidsList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.binding.Pdbids) _pdbidsList.get(index);
@@ -537,9 +543,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._featuresList.size())
     {
-      throw new IndexOutOfBoundsException("setFeatures: Index value '"
-              + index + "' not in range [0.."
-              + (this._featuresList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setFeatures",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._featuresList.size() - 1)).toString()
+        })); 
     }
 
     this._featuresList.set(index, vFeatures);
@@ -588,9 +596,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._pdbidsList.size())
     {
-      throw new IndexOutOfBoundsException("setPdbids: Index value '"
-              + index + "' not in range [0.."
-              + (this._pdbidsList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setPdbids",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._pdbidsList.size() - 1)).toString()
+          })); 
     }
 
     this._pdbidsList.set(index, vPdbids);
index d30ec14..97d68de 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -299,9 +301,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JGroupList.size())
     {
-      throw new IndexOutOfBoundsException("getJGroup: Index value '"
-              + index + "' not in range [0.."
-              + (this._JGroupList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getJGroup",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._JGroupList.size() - 1)).toString()
+        }));
     }
 
     return (jalview.binding.JGroup) _JGroupList.get(index);
@@ -346,8 +350,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JSeqList.size())
     {
-      throw new IndexOutOfBoundsException("getJSeq: Index value '" + index
-              + "' not in range [0.." + (this._JSeqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getJSeq",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._JSeqList.size() - 1)).toString()
+          }));
     }
 
     return (jalview.binding.JSeq) _JSeqList.get(index);
@@ -392,8 +399,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("getTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getJgetTreeSeq",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._treeList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.binding.Tree) _treeList.get(index);
@@ -438,9 +448,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._userColoursList.size())
     {
-      throw new IndexOutOfBoundsException("getUserColours: Index value '"
-              + index + "' not in range [0.."
-              + (this._userColoursList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getUserColours",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._userColoursList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.binding.UserColours) _userColoursList.get(index);
@@ -486,9 +498,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._viewportList.size())
     {
-      throw new IndexOutOfBoundsException("getViewport: Index value '"
-              + index + "' not in range [0.."
-              + (this._viewportList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getViewport",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._viewportList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.binding.Viewport) _viewportList.get(index);
@@ -756,9 +770,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JGroupList.size())
     {
-      throw new IndexOutOfBoundsException("setJGroup: Index value '"
-              + index + "' not in range [0.."
-              + (this._JGroupList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setJGroup",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._JGroupList.size() - 1)).toString()
+          })); 
     }
 
     this._JGroupList.set(index, vJGroup);
@@ -794,8 +810,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JSeqList.size())
     {
-      throw new IndexOutOfBoundsException("setJSeq: Index value '" + index
-              + "' not in range [0.." + (this._JSeqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setJSeq",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._JSeqList.size() - 1)).toString()
+        })); 
     }
 
     this._JSeqList.set(index, vJSeq);
@@ -831,8 +850,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("setTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setTree",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._treeList.size() - 1)).toString()
+          })); 
     }
 
     this._treeList.set(index, vTree);
@@ -869,9 +891,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._userColoursList.size())
     {
-      throw new IndexOutOfBoundsException("setUserColours: Index value '"
-              + index + "' not in range [0.."
-              + (this._userColoursList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setUserColours",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._userColoursList.size() - 1)).toString()
+        })); 
     }
 
     this._userColoursList.set(index, vUserColours);
@@ -909,9 +933,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._viewportList.size())
     {
-      throw new IndexOutOfBoundsException("setViewport: Index value '"
-              + index + "' not in range [0.."
-              + (this._viewportList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setViewport",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._viewportList.size() - 1)).toString()
+          })); 
     }
 
     this._viewportList.set(index, vViewport);
index 7473bc7..8b70bcf 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -120,9 +122,11 @@ public class JalviewUserColours implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._colourList.size())
     {
-      throw new IndexOutOfBoundsException("getColour: Index value '"
-              + index + "' not in range [0.."
-              + (this._colourList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getColour",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._colourList.size() - 1)).toString()
+        })); 
     }
 
     return (Colour) _colourList.get(index);
@@ -274,9 +278,11 @@ public class JalviewUserColours implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._colourList.size())
     {
-      throw new IndexOutOfBoundsException("setColour: Index value '"
-              + index + "' not in range [0.."
-              + (this._colourList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setColour",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._colourList.size() - 1)).toString()
+          })); 
     }
 
     this._colourList.set(index, vColour);
index 2ee5c96..9b7c1cf 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -131,9 +133,11 @@ public class Pdbentry implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._items.size())
     {
-      throw new IndexOutOfBoundsException("getPdbentryItem: Index value '"
-              + index + "' not in range [0.." + (this._items.size() - 1)
-              + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getPdbentryItem",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._items.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.binding.PdbentryItem) _items.get(index);
@@ -286,9 +290,11 @@ public class Pdbentry implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._items.size())
     {
-      throw new IndexOutOfBoundsException("setPdbentryItem: Index value '"
-              + index + "' not in range [0.." + (this._items.size() - 1)
-              + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setPdbentryItem",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._items.size() - 1)).toString()
+          })); 
     }
 
     this._items.set(index, vPdbentryItem);
index abd3fab..f24d281 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.binding;
 
+import jalview.util.MessageManager;
+
 /**
  * Class PdbentryItem.
  * 
@@ -103,9 +105,11 @@ public class PdbentryItem implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._propertyList.size())
     {
-      throw new IndexOutOfBoundsException("getProperty: Index value '"
-              + index + "' not in range [0.."
-              + (this._propertyList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getProperty",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._propertyList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.binding.Property) _propertyList.get(index);
@@ -182,9 +186,11 @@ public class PdbentryItem implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._propertyList.size())
     {
-      throw new IndexOutOfBoundsException("setProperty: Index value '"
-              + index + "' not in range [0.."
-              + (this._propertyList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setProperty",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._propertyList.size() - 1)).toString()
+          })); 
     }
 
     this._propertyList.set(index, vProperty);
index 85b4889..59151c8 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -186,9 +188,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationList.size())
     {
-      throw new IndexOutOfBoundsException("getAnnotation: Index value '"
-              + index + "' not in range [0.."
-              + (this._annotationList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getAnnotation",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._annotationList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.binding.Annotation) _annotationList.get(index);
@@ -244,9 +248,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceList.size())
     {
-      throw new IndexOutOfBoundsException("getSequence: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getSequence",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._sequenceList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.binding.Sequence) _sequenceList.get(index);
@@ -441,9 +447,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationList.size())
     {
-      throw new IndexOutOfBoundsException("setAnnotation: Index value '"
-              + index + "' not in range [0.."
-              + (this._annotationList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setAnnotation",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._annotationList.size() - 1)).toString()
+        })); 
     }
 
     this._annotationList.set(index, vAnnotation);
@@ -492,9 +500,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceList.size())
     {
-      throw new IndexOutOfBoundsException("setSequence: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setSequence",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._sequenceList.size() - 1)).toString()
+          })); 
     }
 
     this._sequenceList.set(index, vSequence);
index 0d1f789..bd4ea40 100644 (file)
@@ -24,6 +24,8 @@ package jalview.binding;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -195,9 +197,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alignmentList.size())
     {
-      throw new IndexOutOfBoundsException("getAlignment: Index value '"
-              + index + "' not in range [0.."
-              + (this._alignmentList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getAlignment",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._alignmentList.size() - 1)).toString()
+        })); 
     }
 
     return (Alignment) _alignmentList.get(index);
@@ -242,9 +246,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceSetList.size())
     {
-      throw new IndexOutOfBoundsException("getSequenceSet: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceSetList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getSequenceSet",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._sequenceSetList.size() - 1)).toString()
+          })); 
     }
 
     return (SequenceSet) _sequenceSetList.get(index);
@@ -289,8 +295,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("getTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getTree",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._treeList.size() - 1)).toString()
+        })); 
     }
 
     return (java.lang.String) _treeList.get(index);
@@ -482,9 +491,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alignmentList.size())
     {
-      throw new IndexOutOfBoundsException("setAlignment: Index value '"
-              + index + "' not in range [0.."
-              + (this._alignmentList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setAlignment",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._alignmentList.size() - 1)).toString()
+          })); 
     }
 
     this._alignmentList.set(index, vAlignment);
@@ -520,9 +531,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceSetList.size())
     {
-      throw new IndexOutOfBoundsException("setSequenceSet: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceSetList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setSequenceSet",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._sequenceSetList.size() - 1)).toString()
+        })); 
     }
 
     this._sequenceSetList.set(index, vSequenceSet);
@@ -558,8 +571,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("setTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setTree",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._treeList.size() - 1)).toString()
+          })); 
     }
 
     this._treeList.set(index, vTree);
index 077f9cd..dbc3524 100644 (file)
@@ -35,6 +35,7 @@ import jalview.datamodel.SequenceCollectionI;
 import jalview.datamodel.SequenceFeature;
 import jalview.datamodel.SequenceGroup;
 import jalview.datamodel.SequenceI;
+import jalview.util.MessageManager;
 
 public class AlignViewController implements AlignViewControllerI
 {
@@ -276,16 +277,17 @@ public class AlignViewController implements AlignViewControllerI
       }
       viewport.setColumnSelection(cs);
       alignPanel.paintAlignment(true);
-      avcg.setStatus((toggle ? "Toggled " : "Marked ")
-              + (invert ? (alw - alStart) - bs.cardinality() : bs
-                      .cardinality()) + " columns "
-              + (invert ? "not " : "") + "containing features of type "
-              + featureType + " across " + nseq + " sequence(s)");
+      avcg.setStatus(MessageManager.formatMessage("label.view_controller_toggled_marked",
+                 new String[]{
+                               (toggle ? MessageManager.getString("label.toggled") : MessageManager.getString("label.marked")),
+                               (invert ? (Integer.valueOf((alw - alStart) - bs.cardinality()).toString()):(Integer.valueOf(bs.cardinality()).toString())),
+                               featureType, Integer.valueOf(nseq).toString()
+                       }));
       return true;
     }
     else
     {
-      avcg.setStatus("No features of type " + featureType + " found.");
+      avcg.setStatus(MessageManager.formatMessage("label.no_feature_of_type_found", new String[]{featureType}));
       if (!extendCurrent && cs != null)
       {
         cs.clear();
index ad7cdd2..5e75725 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package jalview.datamodel;
 
+import jalview.util.MessageManager;
+
 import java.util.*;
 
 /**
@@ -112,7 +114,7 @@ public class Alignment implements AlignmentI
    */
   public static AlignmentI createAlignment(CigarArray compactAlignment)
   {
-    throw new Error("Alignment(CigarArray) not yet implemented");
+    throw new Error(MessageManager.getString("error.alignment_cigararray_not_implemented"));
     // this(compactAlignment.refCigars);
   }
 
index c0f9ab4..a17881e 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package jalview.datamodel;
 
+import jalview.util.MessageManager;
+
 import java.util.*;
 
 public class AlignmentOrder
@@ -217,7 +219,7 @@ public class AlignmentOrder
       {
         if (!identity)
         {
-          throw new Error("Weak sequenceI equivalence not yet implemented.");
+          throw new Error(MessageManager.getString("error.weak_sequencei_equivalence_not_yet_implemented"));
         }
         else
         {
@@ -284,7 +286,7 @@ public class AlignmentOrder
         }
         if (!identity)
         {
-          throw new Error("Weak sequenceI equivalence not yet implemented.");
+          throw new Error(MessageManager.getString("error.weak_sequencei_equivalence_not_yet_implemented"));
         }
         else
         {
index 6c4cfae..efb7c4a 100644 (file)
@@ -20,6 +20,7 @@
  */
 package jalview.datamodel;
 
+import jalview.util.MessageManager;
 import jalview.util.ShiftList;
 
 import java.io.PrintStream;
@@ -241,8 +242,7 @@ public class AlignmentView
   {
     if (!seqcigararray.isSeqCigarArray())
     {
-      throw new Error(
-              "Implementation Error - can only make an alignment view from a CigarArray of sequences.");
+      throw new Error(MessageManager.getString("error.implementation_error_can_only_make_alignmnet_from_cigararray"));
     }
     // contigs = seqcigararray.applyDeletions();
     contigs = seqcigararray.getDeletedRegions();
@@ -652,7 +652,7 @@ public class AlignmentView
   {
     if (sequences == null || width <= 0)
     {
-      throw new Error("empty view cannot be updated.");
+      throw new Error(MessageManager.getString("error.empty_view_cannot_be_updated"));
     }
     if (nvismsa == null)
     {
@@ -682,11 +682,7 @@ public class AlignmentView
               j++;
               if (mseq.length != sequences.length)
               {
-                throw new Error(
-                        "Mismatch between number of sequences in block "
-                                + j + " (" + mseq.length
-                                + ") and the original view ("
-                                + sequences.length + ")");
+                throw new Error(MessageManager.formatMessage("error.mismatch_between_number_of_sequences_in_block", new String[]{Integer.valueOf(j).toString(),Integer.valueOf(mseq.length).toString(),Integer.valueOf(sequences.length).toString() }));
               }
               swidth = mseq[0].getLength(); // JBPNote: could ensure padded
               // here.
@@ -839,7 +835,7 @@ public class AlignmentView
               else
               {
                 // place gaps.
-                throw new Error("Padding not yet implemented.");
+                throw new Error(MessageManager.getString("error.padding_not_yet_implemented"));
               }
             }
           }
@@ -852,9 +848,7 @@ public class AlignmentView
     {
       if (nvismsa.length != 1)
       {
-        throw new Error(
-                "Mismatch between visible blocks to update and number of contigs in view (contigs=0,blocks="
-                        + nvismsa.length);
+        throw new Error(MessageManager.formatMessage("error.mismatch_between_visible_blocks_to_update_and_number_of_contigs_in_view", new String[]{Integer.valueOf(nvismsa.length).toString()}));
       }
       if (nvismsa[0] != null)
       {
index 69826b6..d0ead87 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.datamodel;
 
+import jalview.util.MessageManager;
+
 import java.util.*;
 
 public abstract class CigarBase
@@ -144,7 +146,7 @@ public abstract class CigarBase
         endpos = alcursor;
         break;
       default:
-        throw new Error("Unknown SeqCigar operation '" + operation[i] + "'");
+        throw new Error(MessageManager.formatMessage("error.unknown_seq_cigar_operation", new String[]{new StringBuffer(operation[i]).toString()}));
       }
     }
     if (++delcount > 0)
@@ -223,7 +225,7 @@ public abstract class CigarBase
       } while (c >= '0' && c <= '9' && j < l);
       if (j >= l && c >= '0' && c <= '9')
       {
-        throw new Exception("Unterminated cigar string.");
+        throw new Exception(MessageManager.getString("exception.unterminated_cigar_string"));
       }
       try
       {
@@ -232,7 +234,7 @@ public abstract class CigarBase
         i = j;
       } catch (Exception e)
       {
-        throw new Error("Implementation bug in parseCigarString");
+        throw new Error(MessageManager.getString("error.implementation_bug_parse_cigar_string"));
       }
       if (c >= 'a' && c <= 'z')
       {
@@ -244,9 +246,11 @@ public abstract class CigarBase
       }
       else
       {
-        throw new Exception("Unexpected operation '" + c
-                + "' in cigar string (position " + i + " in '"
-                + cigarString + "'");
+        throw new Exception(MessageManager.formatMessage("exception.unexpected_operation_cigar_string_pos", new String[]{
+                       new StringBuffer(c).toString(),
+                       Integer.valueOf(i).toString(),
+                       cigarString
+        }));
       }
     }
     return new Object[]
@@ -269,7 +273,7 @@ public abstract class CigarBase
     }
     if (op != M && op != D && op != I)
     {
-      throw new Error("Implementation error. Invalid operation string.");
+      throw new Error(MessageManager.getString("error.implementation_error_invalid_operation_string"));
     }
     if (range == 0)
     {
@@ -277,8 +281,7 @@ public abstract class CigarBase
     }
     if (range < 0)
     {
-      throw new Error(
-              "Invalid range string (must be zero or positive number)");
+      throw new Error(MessageManager.getString("error.invalid_range_string"));
     }
     int lngth = 0;
     if (operation == null)
@@ -390,8 +393,7 @@ public abstract class CigarBase
     }
     if (start < 0 || start > end)
     {
-      throw new Error(
-              "Implementation Error: deleteRange out of bounds: start must be non-negative and less than end.");
+      throw new Error(MessageManager.getString("error.implementation_error_delete_range_out_of_bounds"));
     }
     // find beginning
     int cursor = 0; // mark the position for the current operation being edited.
@@ -463,10 +465,9 @@ public abstract class CigarBase
           }
           break;
         case D:
-          throw new Error("Implementation error."); // do nothing;
+          throw new Error(MessageManager.getString("error.implementation_error")); // do nothing;
         default:
-          throw new Error("Implementation Error! Unknown operation '"
-                  + oldops[o] + "'");
+          throw new Error(MessageManager.formatMessage("error.implementation_error_unknown_operation", new String[]{new StringBuffer(oldops[o]).toString()}));
         }
         rlength -= remain;
         remain = oldrange[++o]; // number of op characters left to edit
index ffe152b..8441609 100644 (file)
@@ -93,8 +93,7 @@ public class SeqCigar extends CigarSimple
             refseq.getSequenceAsString(start, end), GapChar);
     if (edit_result == null)
     {
-      throw new Error(
-              "Implementation Error - unexpected null from getSequenceAndDeletions");
+      throw new Error(MessageManager.getString("error.implementation_error_unexpected_null_from_get_sequence_and_deletions"));
     }
     int bounds[] = (int[]) edit_result[1];
     seq = new Sequence(refseq.getName(), (String) edit_result[0],
@@ -142,11 +141,11 @@ public class SeqCigar extends CigarSimple
     boolean hasgaps = false;
     if (seq == null)
     {
-      throw new Error("Implementation Error - _setSeq(null,...)");
+      throw new Error(MessageManager.getString("error.implementation_error_set_seq_null"));
     }
     if (_s < 0)
     {
-      throw new Error("Implementation Error: _s=" + _s);
+      throw new Error(MessageManager.formatMessage("error.implementation_error_s", new String[]{Integer.valueOf(_s).toString()}));
     }
     String seq_string = seq.getSequenceAsString();
     if (_e == 0 || _e < _s || _e > seq_string.length())
@@ -212,8 +211,7 @@ public class SeqCigar extends CigarSimple
     // Check offsets
     if (end > ds.getLength())
     {
-      throw new Error(
-              "SeqCigar: Possible implementation error: sequence is longer than dataset sequence");
+      throw new Error(MessageManager.getString("error.implementation_error_seqcigar_possible"));
       // end = ds.getLength();
     }
 
@@ -237,12 +235,11 @@ public class SeqCigar extends CigarSimple
     super();
     if (seq == null)
     {
-      throw new Error("Implementation Bug. Null seq !");
+      throw new Error(MessageManager.getString("error.implmentation_bug_seq_null"));
     }
     if (operation.length != range.length)
     {
-      throw new Error(
-              "Implementation Bug. Cigar Operation list!= range list");
+      throw new Error(MessageManager.getString("error.implementation_bug_cigar_operation_list_range_list"));
     }
 
     if (operation != null)
@@ -252,17 +249,14 @@ public class SeqCigar extends CigarSimple
 
       if (_setSeq(seq, false, 0, 0))
       {
-        throw new Error(
-                "NOT YET Implemented: Constructing a Cigar object from a cigar string and a gapped sequence.");
+        throw new Error(MessageManager.getString("error.not_yet_implemented_cigar_object_from_cigar_string"));
       }
       for (int i = this.length, j = 0; j < operation.length; i++, j++)
       {
         char op = operation[j];
         if (op != M && op != I && op != D)
         {
-          throw new Error("Implementation Bug. Cigar Operation '" + j
-                  + "' '" + op + "' not one of '" + M + "', '" + I
-                  + "', or '" + D + "'.");
+          throw new Error(MessageManager.formatMessage("error.implementation_bug_cigar_operation", new String[]{Integer.valueOf(j).toString(),Integer.valueOf(op).toString(),Integer.valueOf(M).toString(),Integer.valueOf(I).toString(),Integer.valueOf(D).toString()}));
         }
         this.operation[i] = op;
         this.range[i] = range[j];
@@ -276,8 +270,7 @@ public class SeqCigar extends CigarSimple
       this.length = 0;
       if (_setSeq(seq, false, 0, 0))
       {
-        throw new Error(
-                "NOT YET Implemented: Constructing a Cigar object from a cigar string and a gapped sequence.");
+        throw new Error(MessageManager.getString("error.not_yet_implemented_cigar_object_from_cigar_string"));
       }
     }
   }
@@ -384,7 +377,7 @@ public class SeqCigar extends CigarSimple
     super();
     if (seq == null)
     {
-      throw new Error("Implementation error for new Cigar(SequenceI)");
+      throw new Error(MessageManager.getString("error.implementation_error_for_new_cigar"));
     }
     _setSeq(seq, false, 0, 0);
     // there is still work to do
@@ -406,7 +399,7 @@ public class SeqCigar extends CigarSimple
     super();
     if (seq == null)
     {
-      throw new Error("Implementation error for new Cigar(SequenceI)");
+      throw new Error(MessageManager.getString("error.implementation_error_for_new_cigar"));
     }
     _setSeq(seq, false, start, end + 1);
     // there is still work to do
@@ -461,8 +454,7 @@ public class SeqCigar extends CigarSimple
       // endcol}, hidden regions {{start, end, col}})
       if (gs_regions[i] == null)
       {
-        throw new Error("Implementation error: " + i
-                + "'th sequence Cigar has no operations.");
+        throw new Error(MessageManager.formatMessage("error.implementation_error_cigar_seq_no_operations", new String[]{Integer.valueOf(i).toString()}));
       }
       g_seqs[i] = new StringBuffer((String) ((Object[]) gs_regions[i])[0]); // the
       // visible
index d002031..945a9d4 100755 (executable)
@@ -59,8 +59,10 @@ public class Sequence implements SequenceI
   /**
    * This annotation is displayed below the alignment but the positions are tied
    * to the residues of this sequence
+   *
+   * TODO: change to List<>
    */
-  Vector annotation;
+  Vector<AlignmentAnnotation> annotation;
 
   /**
    * The index of the sequence in a MSA
@@ -1005,14 +1007,13 @@ public class Sequence implements SequenceI
       datasetSequence.updatePDBIds();
       if (annotation != null)
       {
-        Vector<AlignmentAnnotation> _annot = annotation;
-        annotation = null;
-        for (AlignmentAnnotation aa : _annot)
+        for (AlignmentAnnotation aa : annotation)
         {
-          aa.sequenceRef = datasetSequence;
-          aa.adjustForAlignment(); // uses annotation's own record of
+          AlignmentAnnotation _aa = new AlignmentAnnotation(aa);
+          _aa.sequenceRef = datasetSequence;
+          _aa.adjustForAlignment(); // uses annotation's own record of
                                    // sequence-column mapping
-          datasetSequence.addAlignmentAnnotation(aa);
+          datasetSequence.addAlignmentAnnotation(_aa);
         }
       }
     }
index e9259dd..b10a4d4 100755 (executable)
-/*
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2)
- * Copyright (C) 2014 The Jalview Authors
- * 
- * This file is part of Jalview.
- * 
- * Jalview is free software: you can redistribute it and/or
- * modify it under the terms of the GNU General Public License 
- * as published by the Free Software Foundation, either version 3
- * of the License, or (at your option) any later version.
- *  
- * Jalview is distributed in the hope that it will be useful, but 
- * WITHOUT ANY WARRANTY; without even the implied warranty 
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
- * PURPOSE.  See the GNU General Public License for more details.
- * 
- * You should have received a copy of the GNU General Public License
- * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
- * The Jalview Authors are detailed in the 'AUTHORS' file.
- */
-package jalview.datamodel;
-
-import java.util.Vector;
-
-import fr.orsay.lri.varna.models.rna.RNA;
-
-/**
- * DOCUMENT ME!
- * 
- * @author $author$
- * @version $Revision$
- */
-public interface SequenceI
-{
-  /**
-   * Set the display name for the sequence
-   * 
-   * @param name
-   */
-  public void setName(String name);
-
-  /**
-   * Get the display name
-   */
-  public String getName();
-
-  /**
-   * Set start position of first non-gapped symbol in sequence
-   * 
-   * @param start
-   *          new start position
-   */
-  public void setStart(int start);
-
-  /**
-   * get start position of first non-gapped residue in sequence
-   * 
-   * @return
-   */
-  public int getStart();
-
-  /**
-   * get the displayed id of the sequence
-   * 
-   * @return true means the id will be returned in the form
-   *         DisplayName/Start-End
-   */
-  public String getDisplayId(boolean jvsuffix);
-
-  /**
-   * set end position for last residue in sequence
-   * 
-   * @param end
-   */
-  public void setEnd(int end);
-
-  /**
-   * get end position for last residue in sequence getEnd()>getStart() unless
-   * sequence only consists of gap characters
-   * 
-   * @return
-   */
-  public int getEnd();
-
-  /**
-   * @return length of sequence including gaps
-   * 
-   */
-  public int getLength();
-
-  /**
-   * Replace the sequence with the given string
-   * 
-   * @param sequence
-   *          new sequence string
-   */
-  public void setSequence(String sequence);
-
-  /**
-   * @return sequence as string
-   */
-  public String getSequenceAsString();
-
-  /**
-   * get a range on the sequence as a string
-   * 
-   * @param start
-   *          position relative to start of sequence including gaps (from 0)
-   * @param end
-   *          position relative to start of sequence including gaps (from 0)
-   * 
-   * @return String containing all gap and symbols in specified range
-   */
-  public String getSequenceAsString(int start, int end);
-
-  /**
-   * Get the sequence as a character array
-   * 
-   * @return seqeunce and any gaps
-   */
-  public char[] getSequence();
-
-  /**
-   * get stretch of sequence characters in an array
-   * 
-   * @param start
-   *          absolute index into getSequence()
-   * @param end
-   *          exclusive index of last position in segment to be returned.
-   * 
-   * @return char[max(0,end-start)];
-   */
-  public char[] getSequence(int start, int end);
-
-  /**
-   * create a new sequence object from start to end of this sequence
-   * 
-   * @param start
-   *          int
-   * @param end
-   *          int
-   * @return SequenceI
-   */
-  public SequenceI getSubSequence(int start, int end);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @param i
-   *          DOCUMENT ME!
-   * 
-   * @return DOCUMENT ME!
-   */
-  public char getCharAt(int i);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @param desc
-   *          DOCUMENT ME!
-   */
-  public void setDescription(String desc);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @return DOCUMENT ME!
-   */
-  public String getDescription();
-
-  /**
-   * Return the alignment column for a sequence position * Return the alignment
-   * position for a sequence position
-   * 
-   * @param pos
-   *          lying from start to end
-   * 
-   * @return aligned column for residue (0 if residue is upstream from
-   *         alignment, -1 if residue is downstream from alignment) note.
-   *         Sequence object returns sequence.getEnd() for positions upstream
-   *         currently. TODO: change sequence for
-   *         assert(findIndex(seq.getEnd()+1)==-1) and fix incremental bugs
-   * 
-   */
-  public int findIndex(int pos);
-
-  /**
-   * Returns the sequence position for an alignment position
-   * 
-   * @param i
-   *          column index in alignment (from 1)
-   * 
-   * @return residue number for residue (left of and) nearest ith column
-   */
-  public int findPosition(int i);
-
-  /**
-   * Returns an int array where indices correspond to each residue in the
-   * sequence and the element value gives its position in the alignment
-   * 
-   * @return int[SequenceI.getEnd()-SequenceI.getStart()+1] or null if no
-   *         residues in SequenceI object
-   */
-  public int[] gapMap();
-
-  /**
-   * Returns an int array where indices correspond to each position in sequence
-   * char array and the element value gives the result of findPosition for that
-   * index in the sequence.
-   * 
-   * @return int[SequenceI.getLength()]
-   */
-  public int[] findPositionMap();
-
-  /**
-   * Delete a range of aligned sequence columns, creating a new dataset sequence
-   * if necessary and adjusting start and end positions accordingly.
-   * 
-   * @param i
-   *          first column in range to delete
-   * @param j
-   *          last column in range to delete
-   */
-  public void deleteChars(int i, int j);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @param i
-   *          DOCUMENT ME!
-   * @param c
-   *          DOCUMENT ME!
-   */
-  public void insertCharAt(int i, char c);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @param i
-   *          DOCUMENT ME!
-   * @param c
-   *          DOCUMENT ME!
-   */
-  public void insertCharAt(int i, int length, char c);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @return DOCUMENT ME!
-   */
-  public SequenceFeature[] getSequenceFeatures();
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @param v
-   *          DOCUMENT ME!
-   */
-  public void setSequenceFeatures(SequenceFeature[] features);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @param id
-   *          DOCUMENT ME!
-   */
-  public void setPDBId(Vector ids);
-
-  /**
-   * DOCUMENT ME!
-   * 
-   * @return DOCUMENT ME!
-   */
-  public Vector getPDBId();
-
-  /**
-   * add entry to the vector of PDBIds, if it isn't in the list already
-   * 
-   * @param entry
-   */
-  public void addPDBId(PDBEntry entry);
-
-  /**
-   * update the list of PDBEntrys to include any DBRefEntrys citing structural
-   * databases
-   * 
-   * @return true if PDBEntry list was modified
-   */
-  public boolean updatePDBIds();
-
-  public String getVamsasId();
-
-  public void setVamsasId(String id);
-
-  public void setDBRef(DBRefEntry[] dbs);
-
-  public DBRefEntry[] getDBRef();
-
-  /**
-   * add the given entry to the list of DBRefs for this sequence, or replace a
-   * similar one if entry contains a map object and the existing one doesnt.
-   * 
-   * @param entry
-   */
-  public void addDBRef(DBRefEntry entry);
-
-  public void addSequenceFeature(SequenceFeature sf);
-
-  public void deleteFeature(SequenceFeature sf);
-
-  public void setDatasetSequence(SequenceI seq);
-
-  public SequenceI getDatasetSequence();
-
-  public AlignmentAnnotation[] getAnnotation();
-
-  public void addAlignmentAnnotation(AlignmentAnnotation annotation);
-
-  public void removeAlignmentAnnotation(AlignmentAnnotation annotation);
-
-  /**
-   * Derive a sequence (using this one's dataset or as the dataset)
-   * 
-   * @return duplicate sequence with valid dataset sequence
-   */
-  public SequenceI deriveSequence();
-
-  /**
-   * set the array of associated AlignmentAnnotation for this sequenceI
-   * 
-   * @param revealed
-   */
-  public void setAlignmentAnnotation(AlignmentAnnotation[] annotation);
-
-  /**
-   * Get one or more alignment annotations with a particular label.
-   * 
-   * @param label
-   *          string which each returned annotation must have as a label.
-   * @return null or array of annotations.
-   */
-  public AlignmentAnnotation[] getAnnotation(String label);
-
-  /**
-   * create a new dataset sequence (if necessary) for this sequence and sets
-   * this sequence to refer to it. This call will move any features or
-   * references on the sequence onto the dataset.
-   * 
-   * @return dataset sequence for this sequence
-   */
-  public SequenceI createDatasetSequence();
-
-  /**
-   * Transfer any database references or annotation from entry under a sequence
-   * mapping.
-   * 
-   * @param entry
-   * @param mp
-   *          null or mapping from entry's numbering to local start/end
-   */
-  public void transferAnnotation(SequenceI entry, Mapping mp);
-
-  /**
-   * @param index
-   *          The sequence index in the MSA
-   */
-  public void setIndex(int index);
-
-  /**
-   * @return The index of the sequence in the alignment
-   */
-  public int getIndex();
-
-  /**
-   * @return The RNA of the sequence in the alignment
-   */
-
-  public RNA getRNA();
-
-  /**
-   * @param rna
-   *          The RNA.
-   */
-  public void setRNA(RNA rna);
-
-}
+/*\r
+ * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2)\r
+ * Copyright (C) 2014 The Jalview Authors\r
+ * \r
+ * This file is part of Jalview.\r
+ * \r
+ * Jalview is free software: you can redistribute it and/or\r
+ * modify it under the terms of the GNU General Public License \r
+ * as published by the Free Software Foundation, either version 3\r
+ * of the License, or (at your option) any later version.\r
+ *  \r
+ * Jalview is distributed in the hope that it will be useful, but \r
+ * WITHOUT ANY WARRANTY; without even the implied warranty \r
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR \r
+ * PURPOSE.  See the GNU General Public License for more details.\r
+ * \r
+ * You should have received a copy of the GNU General Public License\r
+ * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.\r
+ * The Jalview Authors are detailed in the 'AUTHORS' file.\r
+ */\r
+package jalview.datamodel;\r
+\r
+import java.util.Vector;\r
+\r
+import fr.orsay.lri.varna.models.rna.RNA;\r
+\r
+/**\r
+ * DOCUMENT ME!\r
+ * \r
+ * @author $author$\r
+ * @version $Revision$\r
+ */\r
+public interface SequenceI\r
+{\r
+  /**\r
+   * Set the display name for the sequence\r
+   * \r
+   * @param name\r
+   */\r
+  public void setName(String name);\r
+\r
+  /**\r
+   * Get the display name\r
+   */\r
+  public String getName();\r
+\r
+  /**\r
+   * Set start position of first non-gapped symbol in sequence\r
+   * \r
+   * @param start\r
+   *          new start position\r
+   */\r
+  public void setStart(int start);\r
+\r
+  /**\r
+   * get start position of first non-gapped residue in sequence\r
+   * \r
+   * @return\r
+   */\r
+  public int getStart();\r
+\r
+  /**\r
+   * get the displayed id of the sequence\r
+   * \r
+   * @return true means the id will be returned in the form\r
+   *         DisplayName/Start-End\r
+   */\r
+  public String getDisplayId(boolean jvsuffix);\r
+\r
+  /**\r
+   * set end position for last residue in sequence\r
+   * \r
+   * @param end\r
+   */\r
+  public void setEnd(int end);\r
+\r
+  /**\r
+   * get end position for last residue in sequence getEnd()>getStart() unless\r
+   * sequence only consists of gap characters\r
+   * \r
+   * @return\r
+   */\r
+  public int getEnd();\r
+\r
+  /**\r
+   * @return length of sequence including gaps\r
+   * \r
+   */\r
+  public int getLength();\r
+\r
+  /**\r
+   * Replace the sequence with the given string\r
+   * \r
+   * @param sequence\r
+   *          new sequence string\r
+   */\r
+  public void setSequence(String sequence);\r
+\r
+  /**\r
+   * @return sequence as string\r
+   */\r
+  public String getSequenceAsString();\r
+\r
+  /**\r
+   * get a range on the sequence as a string\r
+   * \r
+   * @param start\r
+   *          position relative to start of sequence including gaps (from 0)\r
+   * @param end\r
+   *          position relative to start of sequence including gaps (from 0)\r
+   * \r
+   * @return String containing all gap and symbols in specified range\r
+   */\r
+  public String getSequenceAsString(int start, int end);\r
+\r
+  /**\r
+   * Get the sequence as a character array\r
+   * \r
+   * @return seqeunce and any gaps\r
+   */\r
+  public char[] getSequence();\r
+\r
+  /**\r
+   * get stretch of sequence characters in an array\r
+   * \r
+   * @param start\r
+   *          absolute index into getSequence()\r
+   * @param end\r
+   *          exclusive index of last position in segment to be returned.\r
+   * \r
+   * @return char[max(0,end-start)];\r
+   */\r
+  public char[] getSequence(int start, int end);\r
+\r
+  /**\r
+   * create a new sequence object from start to end of this sequence\r
+   * \r
+   * @param start\r
+   *          int\r
+   * @param end\r
+   *          int\r
+   * @return SequenceI\r
+   */\r
+  public SequenceI getSubSequence(int start, int end);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @param i\r
+   *          DOCUMENT ME!\r
+   * \r
+   * @return DOCUMENT ME!\r
+   */\r
+  public char getCharAt(int i);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @param desc\r
+   *          DOCUMENT ME!\r
+   */\r
+  public void setDescription(String desc);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @return DOCUMENT ME!\r
+   */\r
+  public String getDescription();\r
+\r
+  /**\r
+   * Return the alignment column for a sequence position * Return the alignment\r
+   * position for a sequence position\r
+   * \r
+   * @param pos\r
+   *          lying from start to end\r
+   * \r
+   * @return aligned column for residue (0 if residue is upstream from\r
+   *         alignment, -1 if residue is downstream from alignment) note.\r
+   *         Sequence object returns sequence.getEnd() for positions upstream\r
+   *         currently. TODO: change sequence for\r
+   *         assert(findIndex(seq.getEnd()+1)==-1) and fix incremental bugs\r
+   * \r
+   */\r
+  public int findIndex(int pos);\r
+\r
+  /**\r
+   * Returns the sequence position for an alignment position\r
+   * \r
+   * @param i\r
+   *          column index in alignment (from 1)\r
+   * \r
+   * @return residue number for residue (left of and) nearest ith column\r
+   */\r
+  public int findPosition(int i);\r
+\r
+  /**\r
+   * Returns an int array where indices correspond to each residue in the\r
+   * sequence and the element value gives its position in the alignment\r
+   * \r
+   * @return int[SequenceI.getEnd()-SequenceI.getStart()+1] or null if no\r
+   *         residues in SequenceI object\r
+   */\r
+  public int[] gapMap();\r
+\r
+  /**\r
+   * Returns an int array where indices correspond to each position in sequence\r
+   * char array and the element value gives the result of findPosition for that\r
+   * index in the sequence.\r
+   * \r
+   * @return int[SequenceI.getLength()]\r
+   */\r
+  public int[] findPositionMap();\r
+\r
+  /**\r
+   * Delete a range of aligned sequence columns, creating a new dataset sequence\r
+   * if necessary and adjusting start and end positions accordingly.\r
+   * \r
+   * @param i\r
+   *          first column in range to delete\r
+   * @param j\r
+   *          last column in range to delete\r
+   */\r
+  public void deleteChars(int i, int j);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @param i\r
+   *          DOCUMENT ME!\r
+   * @param c\r
+   *          DOCUMENT ME!\r
+   */\r
+  public void insertCharAt(int i, char c);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @param i\r
+   *          DOCUMENT ME!\r
+   * @param c\r
+   *          DOCUMENT ME!\r
+   */\r
+  public void insertCharAt(int i, int length, char c);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @return DOCUMENT ME!\r
+   */\r
+  public SequenceFeature[] getSequenceFeatures();\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @param v\r
+   *          DOCUMENT ME!\r
+   */\r
+  public void setSequenceFeatures(SequenceFeature[] features);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @param id\r
+   *          DOCUMENT ME!\r
+   */\r
+  public void setPDBId(Vector ids);\r
+\r
+  /**\r
+   * DOCUMENT ME!\r
+   * \r
+   * @return DOCUMENT ME!\r
+   */\r
+  public Vector getPDBId();\r
+\r
+  /**\r
+   * add entry to the vector of PDBIds, if it isn't in the list already\r
+   * \r
+   * @param entry\r
+   */\r
+  public void addPDBId(PDBEntry entry);\r
+\r
+  /**\r
+   * update the list of PDBEntrys to include any DBRefEntrys citing structural\r
+   * databases\r
+   * \r
+   * @return true if PDBEntry list was modified\r
+   */\r
+  public boolean updatePDBIds();\r
+\r
+  public String getVamsasId();\r
+\r
+  public void setVamsasId(String id);\r
+\r
+  public void setDBRef(DBRefEntry[] dbs);\r
+\r
+  public DBRefEntry[] getDBRef();\r
+\r
+  /**\r
+   * add the given entry to the list of DBRefs for this sequence, or replace a\r
+   * similar one if entry contains a map object and the existing one doesnt.\r
+   * \r
+   * @param entry\r
+   */\r
+  public void addDBRef(DBRefEntry entry);\r
+\r
+  public void addSequenceFeature(SequenceFeature sf);\r
+\r
+  public void deleteFeature(SequenceFeature sf);\r
+\r
+  public void setDatasetSequence(SequenceI seq);\r
+\r
+  public SequenceI getDatasetSequence();\r
+\r
+  public AlignmentAnnotation[] getAnnotation();\r
+\r
+  public void addAlignmentAnnotation(AlignmentAnnotation annotation);\r
+\r
+  public void removeAlignmentAnnotation(AlignmentAnnotation annotation);\r
+\r
+  /**\r
+   * Derive a sequence (using this one's dataset or as the dataset)\r
+   * \r
+   * @return duplicate sequence with valid dataset sequence\r
+   */\r
+  public SequenceI deriveSequence();\r
+\r
+  /**\r
+   * set the array of associated AlignmentAnnotation for this sequenceI\r
+   * \r
+   * @param revealed\r
+   */\r
+  public void setAlignmentAnnotation(AlignmentAnnotation[] annotation);\r
+\r
+  /**\r
+   * Get one or more alignment annotations with a particular label.\r
+   * \r
+   * @param label\r
+   *          string which each returned annotation must have as a label.\r
+   * @return null or array of annotations.\r
+   */\r
+  public AlignmentAnnotation[] getAnnotation(String label);\r
+\r
+  /**\r
+   * create a new dataset sequence (if necessary) for this sequence and sets\r
+   * this sequence to refer to it. This call will move any features or\r
+   * references on the sequence onto the dataset. It will also make a duplicate\r
+   * of existing annotation rows for the dataset sequence, rather than relocate\r
+   * them in order to preserve external references (since 2.8.2).\r
+   * \r
+   * @return dataset sequence for this sequence\r
+   */\r
+  public SequenceI createDatasetSequence();\r
+\r
+  /**\r
+   * Transfer any database references or annotation from entry under a sequence\r
+   * mapping. <br/>\r
+   * <strong>Note: DOES NOT transfer sequence associated alignment\r
+   * annotation </strong><br/>\r
+   * \r
+   * @param entry\r
+   * @param mp\r
+   *          null or mapping from entry's numbering to local start/end\r
+   */\r
+  public void transferAnnotation(SequenceI entry, Mapping mp);\r
+\r
+  /**\r
+   * @param index\r
+   *          The sequence index in the MSA\r
+   */\r
+  public void setIndex(int index);\r
+\r
+  /**\r
+   * @return The index of the sequence in the alignment\r
+   */\r
+  public int getIndex();\r
+\r
+  /**\r
+   * @return The RNA of the sequence in the alignment\r
+   */\r
+\r
+  public RNA getRNA();\r
+\r
+  /**\r
+   * @param rna\r
+   *          The RNA.\r
+   */\r
+  public void setRNA(RNA rna);\r
+\r
+}\r
index cadb205..9187912 100644 (file)
@@ -36,6 +36,7 @@ import jalview.structure.StructureListener;
 import jalview.structure.StructureMapping;
 import jalview.structure.StructureSelectionManager;
 import jalview.structures.models.SequenceStructureBindingModel;
+import jalview.util.MessageManager;
 
 import java.awt.Color;
 import java.awt.Container;
@@ -412,8 +413,7 @@ public abstract class JalviewJmolBinding extends SequenceStructureBindingModel i
         // Jmol callback has completed.
         if (mapping == null || mapping.length < 1)
         {
-          throw new Error(
-                  "Implementation error - Jmol seems to be still working on getting its data - report at http://issues.jalview.org/browse/JAL-1016");
+          throw new Error(MessageManager.getString("error.implementation_error_jmol_getting_data"));
         }
         int lastPos = -1;
         for (int s = 0; s < sequence[pdbfnum].length; s++)
@@ -1574,9 +1574,7 @@ public abstract class JalviewJmolBinding extends SequenceStructureBindingModel i
   {
     if (pe < 0 || pe >= pdbentry.length)
     {
-      throw new Error(
-              "Implementation error - no corresponding pdbentry (for index "
-                      + pe + ") to add sequences mappings to");
+      throw new Error(MessageManager.formatMessage("error.implementation_error_no_pdbentry_from_index", new String[]{Integer.valueOf(pe).toString()}));
     }
     final String nullChain = "TheNullChain";
     Vector s = new Vector();
index 9672268..847453f 100644 (file)
@@ -42,6 +42,7 @@ import jalview.datamodel.Sequence;
 import jalview.datamodel.SequenceI;
 import jalview.io.AlignFile;
 import jalview.io.FileParse;
+import jalview.util.MessageManager;
 
 /**
  * Import and process PDB files with Jmol
@@ -95,10 +96,7 @@ public class PDBFileWithJmol extends AlignFile implements
         jmolApp.startViewer(viewer, null);
       } catch (ClassCastException x)
       {
-        throw new Error(
-                "Jmol version "
-                        + JmolViewer.getJmolVersion()
-                        + " is not compatible with this version of Jalview. Report this problem at issues.jalview.org",
+        throw new Error(MessageManager.formatMessage("error.jmol_version_not_compatible_with_jalview_version", new String[]{JmolViewer.getJmolVersion()}),
                 x);
       }
     }
index 4842033..3930fc0 100644 (file)
@@ -20,6 +20,7 @@
  */
 package jalview.ext.paradise;
 
+import jalview.util.MessageManager;
 import jalview.ws.HttpClientUtils;
 
 import java.io.IOException;
@@ -189,14 +190,14 @@ public class Annotate3D
         @Override
         public void remove()
         {
-          throw new Error("Remove: Not implemented");
+          throw new Error(MessageManager.getString("error.not_implemented_remove"));
 
         }
 
         @Override
         protected Object clone() throws CloneNotSupportedException
         {
-          throw new CloneNotSupportedException("Clone: Not implemented");
+          throw new CloneNotSupportedException(MessageManager.getString("error.not_implemented_clone"));
         }
 
         @Override
@@ -217,8 +218,7 @@ public class Annotate3D
       };
     } catch (Exception foo)
     {
-      throw new Exception(
-              "Couldn't parse response from Annotate3d server.", foo);
+      throw new Exception(MessageManager.getString("exception.couldnt_parse_responde_from_annotated3d_server"), foo);
     }
 
   }
index 11aa5c0..a39f355 100644 (file)
@@ -36,6 +36,7 @@ import jalview.structure.StructureListener;
 import jalview.structure.StructureMapping;
 import jalview.structure.StructureSelectionManager;
 import jalview.structures.models.SequenceStructureBindingModel;
+import jalview.util.MessageManager;
 
 import java.awt.Color;
 import java.awt.event.ComponentEvent;
@@ -476,8 +477,7 @@ public abstract class JalviewChimeraBinding extends
         // Jmol callback has completed.
         if (mapping == null || mapping.length < 1)
         {
-          throw new Error(
-                  "Implementation error - Chimera seems to be still working on getting its data - report at http://issues.jalview.org/browse/JAL-1016");
+          throw new Error(MessageManager.getString("error.implementation_error_chimera_getting_data"));
         }
         int lastPos = -1;
         for (int s = 0; s < sequence[pdbfnum].length; s++)
@@ -1350,9 +1350,7 @@ public abstract class JalviewChimeraBinding extends
   {
     if (pe < 0 || pe >= pdbentry.length)
     {
-      throw new Error(
-              "Implementation error - no corresponding pdbentry (for index "
-                      + pe + ") to add sequences mappings to");
+      throw new Error(MessageManager.formatMessage("error.implementation_error_no_pdbentry_from_index", new String[]{Integer.valueOf(pe).toString()}));
     }
     final String nullChain = "TheNullChain";
     Vector s = new Vector();
index e6b7af4..c3d80d1 100644 (file)
@@ -819,8 +819,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   {
     if (progressBarHandlers == null || !progressBars.contains(new Long(id)))
     {
-      throw new Error(
-              "call setProgressBar before registering the progress bar's handler.");
+      throw new Error(MessageManager.getString("error.call_setprogressbar_before_registering_handler"));
     }
     progressBarHandlers.put(new Long(id), handler);
     final JPanel progressPanel = (JPanel) progressBars.get(new Long(id));
@@ -836,10 +835,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         public void actionPerformed(ActionEvent e)
         {
           handler.cancelActivity(id);
-          us.setProgressBar(
-                  "Cancelled "
-                          + ((JLabel) progressPanel.getComponent(0))
-                                  .getText(), id);
+          us.setProgressBar(MessageManager.formatMessage("label.cancelled_params", new String[]{((JLabel) progressPanel.getComponent(0)).getText()}), id);
         }
       });
       progressPanel.add(cancel, BorderLayout.EAST);
@@ -1002,7 +998,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
             currentFileFormat, false);
 
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save Alignment to file");
+    chooser.setDialogTitle(MessageManager.getString("label.save_alignment_to_file"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
@@ -1947,7 +1943,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         // /////
         // ADD HISTORY ITEM
         //
-        addHistoryItem(new EditCommand("Add sequences", EditCommand.PASTE,
+        addHistoryItem(new EditCommand(MessageManager.getString("label.add_sequences"), EditCommand.PASTE,
                 sequences, 0, alignment.getWidth(), alignment));
       }
       // Add any annotations attached to sequences
@@ -2206,7 +2202,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     /*
      * //ADD HISTORY ITEM
      */
-    addHistoryItem(new EditCommand("Cut Sequences", EditCommand.CUT, cut,
+    addHistoryItem(new EditCommand(MessageManager.getString("label.cut_sequences"), EditCommand.CUT, cut,
             sg.getStartRes(), sg.getEndRes() - sg.getStartRes() + 1,
             viewport.getAlignment()));
 
@@ -2610,7 +2606,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     boolean addFirstIndex = false;
     if (viewTitle == null || viewTitle.trim().length() == 0)
     {
-      viewTitle = "View";
+      viewTitle = MessageManager.getString("action.view");
       addFirstIndex = true;
     }
     else
@@ -3888,7 +3884,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
   public void addSortByOrderMenuItem(String title,
           final AlignmentOrder order)
   {
-    final JMenuItem item = new JMenuItem("by " + title);
+    final JMenuItem item = new JMenuItem(MessageManager.formatMessage("action.by_title_param", new String[]{title}));
     sort.add(item);
     item.addActionListener(new java.awt.event.ActionListener()
     {
@@ -4331,12 +4327,11 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
           // object broker mechanism.
           final Vector<JMenu> wsmenu = new Vector<JMenu>();
           final IProgressIndicator af = me;
-          final JMenu msawsmenu = new JMenu("Alignment");
-          final JMenu secstrmenu = new JMenu(
-                  "Secondary Structure Prediction");
-          final JMenu seqsrchmenu = new JMenu("Sequence Database Search");
-          final JMenu analymenu = new JMenu("Analysis");
-          final JMenu dismenu = new JMenu("Protein Disorder");
+          final JMenu msawsmenu = new JMenu(MessageManager.getString("label.alignment"));
+          final JMenu secstrmenu = new JMenu(MessageManager.getString("label.secondary_structure_prediction"));
+          final JMenu seqsrchmenu = new JMenu(MessageManager.getString("label.sequence_database_search"));
+          final JMenu analymenu = new JMenu(MessageManager.getString("label.analysis"));
+          final JMenu dismenu = new JMenu(MessageManager.getString("label.protein_disorder"));
           // JAL-940 - only show secondary structure prediction services from
           // the legacy server
           if (// Cache.getDefault("SHOW_JWS1_SERVICES", true)
@@ -4603,7 +4598,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       public void run()
       {
         final long sttime = System.currentTimeMillis();
-        ths.setProgressBar("Searching for sequences from " + fsrc, sttime);
+        ths.setProgressBar(MessageManager.formatMessage("status.searching_for_sequences_from", new String[]{fsrc}), sttime);
         try
         {
           Alignment ds = ths.getViewport().getAlignment().getDataset(); // update
@@ -4657,7 +4652,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
           jalview.bin.Cache.log.error("Error when finding crossreferences",
                   e);
         }
-        ths.setProgressBar("Finished searching for sequences from " + fsrc,
+        ths.setProgressBar(MessageManager.formatMessage("status.finished_searching_for_sequences_from", new String[]{fsrc}),
                 sttime);
       }
 
@@ -5416,9 +5411,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                   }
 
                 });
-                fetchr.setToolTipText("<html>"
-                        + JvSwingUtils.wrapTooltip("Retrieve from "
-                                + src.getDbName()) + "<html>");
+                fetchr.setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager.formatMessage("label.fetch_retrieve_from", new String[]{src.getDbName()})));
                 dfetch.add(fetchr);
                 comp++;
               }
@@ -5451,15 +5444,11 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                   }
                 });
 
-                fetchr.setToolTipText("<html>"
-                        + JvSwingUtils.wrapTooltip("Retrieve from all "
-                                + otherdb.size() + " sources in "
-                                + src.getDbSource() + "<br>First is :"
-                                + src.getDbName()) + "<html>");
+                fetchr.setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager.formatMessage("label.fetch_retrieve_from_all_sources", new String[]{Integer.valueOf(otherdb.size()).toString(), src.getDbSource(), src.getDbName()})));
                 dfetch.add(fetchr);
                 comp++;
                 // and then build the rest of the individual menus
-                ifetch = new JMenu("Sources from " + src.getDbSource());
+                ifetch = new JMenu(MessageManager.formatMessage("label.source_from_db_source", new String[]{src.getDbSource()}));
                 icomp = 0;
                 String imname = null;
                 int i = 0;
@@ -5472,7 +5461,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                           0, 10) + "..." : dbname;
                   if (imname == null)
                   {
-                    imname = "from '" + sname + "'";
+                    imname = MessageManager.formatMessage("label.from_msname", new String[]{sname});
                   }
                   fetchr = new JMenuItem(msname);
                   final DbSourceProxy[] dassrc =
@@ -5499,8 +5488,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
 
                   });
                   fetchr.setToolTipText("<html>"
-                          + JvSwingUtils.wrapTooltip("Retrieve from "
-                                  + dbname) + "</html>");
+                          + MessageManager.formatMessage("label.fetch_retrieve_from", new String[]{dbname}));
                   ifetch.add(fetchr);
                   ++i;
                   if (++icomp >= mcomp || i == (otherdb.size()))
@@ -5693,8 +5681,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     if (!viewport.getSequenceSetId().equals(
             alignmentPanel.av.getSequenceSetId()))
     {
-      throw new Error(
-              "Implementation error: cannot show a view from another alignment in an AlignFrame.");
+      throw new Error(MessageManager.getString("error.implementation_error_cannot_show_view_alignment_frame"));
     }
     if (tabbedPane != null
             & alignPanels.indexOf(alignmentPanel) != tabbedPane
index 134019d..cdac5b4 100644 (file)
@@ -34,6 +34,7 @@ import jalview.datamodel.*;
 import jalview.jbgui.*;
 import jalview.schemes.*;
 import jalview.structure.StructureSelectionManager;
+import jalview.util.MessageManager;
 
 /**
  * DOCUMENT ME!
@@ -1119,9 +1120,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
             .getProperty("java.awt.headless").equals("true"));
     if (alignFrame != null && !headless)
     {
-      alignFrame.setProgressBar("Saving "
-              + (type == jalview.util.ImageMaker.PNG ? "PNG image"
-                      : "EPS file"), progress);
+      alignFrame.setProgressBar(MessageManager.formatMessage("status.saving_file", new String[]{(type == jalview.util.ImageMaker.PNG ? MessageManager.getString("label.png_image") : MessageManager.getString("label.eps_file"))}), progress);
     }
     try
     {
@@ -1208,7 +1207,7 @@ public class AlignmentPanel extends GAlignmentPanel implements
     {
       if (alignFrame != null && !headless)
       {
-        alignFrame.setProgressBar("Export complete.", progress);
+        alignFrame.setProgressBar(MessageManager.getString("status.export_complete"), progress);
       }
     }
   }
index 39f3a13..7226eb0 100644 (file)
@@ -168,8 +168,7 @@ public class AnnotationColourChooser extends JPanel
         threshold.setSelectedIndex(2);
         break;
       default:
-        throw new Error(
-                "Implementation error: don't know about threshold setting for current AnnotationColourGradient.");
+        throw new Error(MessageManager.getString("error.implementation_error_dont_know_about_thereshold_setting"));
       }
       thresholdIsMin.setSelected(acg.thresholdIsMinMax);
       thresholdValue.setText("" + acg.getAnnotationThreshold());
@@ -472,7 +471,7 @@ public class AnnotationColourChooser extends JPanel
   public void minColour_actionPerformed()
   {
     Color col = JColorChooser.showDialog(this,
-            "Select Colour for Minimum Value", minColour.getBackground());
+            MessageManager.getString("label.select_colour_minimum_value"), minColour.getBackground());
     if (col != null)
     {
       minColour.setBackground(col);
@@ -484,7 +483,7 @@ public class AnnotationColourChooser extends JPanel
   public void maxColour_actionPerformed()
   {
     Color col = JColorChooser.showDialog(this,
-            "Select Colour for Maximum Value", maxColour.getBackground());
+            MessageManager.getString("label.select_colour_maximum_value"), maxColour.getBackground());
     if (col != null)
     {
       maxColour.setBackground(col);
index 0975d24..315c3e2 100644 (file)
@@ -75,7 +75,7 @@ public class AnnotationExporter extends JPanel
     this.ap = ap;
     features = true;
     CSVFormat.setVisible(false);
-    frame.setTitle("Export Features");
+    frame.setTitle(MessageManager.getString("label.export_features"));
   }
 
   public void exportAnnotations(AlignmentPanel ap,
@@ -89,7 +89,7 @@ public class AnnotationExporter extends JPanel
     this.annotations = annotations;
     this.sequenceGroups = list;
     this.alignmentProperties = alProperties;
-    frame.setTitle("Export Annotations");
+    frame.setTitle(MessageManager.getString("label.export_annotations"));
   }
 
   public void toFile_actionPerformed(ActionEvent e)
@@ -98,15 +98,15 @@ public class AnnotationExporter extends JPanel
             jalview.bin.Cache.getProperty("LAST_DIRECTORY"));
 
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle(features ? "Save Features to File"
-            : "Save Annotation to File");
+    chooser.setDialogTitle(features ? MessageManager.getString("label.save_features_to_file")
+            : MessageManager.getString("label.save_annotation_to_file"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
 
     if (value == JalviewFileChooser.APPROVE_OPTION)
     {
-      String text = "No features found on alignment";
+      String text = MessageManager.getString("label.no_features_on_alignment");
       if (features)
       {
         if (GFFFormat.isSelected())
@@ -153,7 +153,7 @@ public class AnnotationExporter extends JPanel
 
   public void toTextbox_actionPerformed(ActionEvent e)
   {
-    String text = "No features found on alignment";
+    String text = MessageManager.getString("label.no_features_on_alignment");
     if (features)
     {
       if (GFFFormat.isSelected())
index b553f56..ec7b46e 100755 (executable)
@@ -43,21 +43,21 @@ import jalview.util.MessageManager;
 public class AnnotationLabels extends JPanel implements MouseListener,
         MouseMotionListener, ActionListener
 {
-  static String TOGGLE_LABELSCALE = "Scale Label to Column";
+  String TOGGLE_LABELSCALE = MessageManager.getString("label.scale_label_to_column");
 
-  static String ADDNEW = "Add New Row";
+  String ADDNEW = MessageManager.getString("label.add_new_row");
 
-  static String EDITNAME = "Edit Label/Description";
+  String EDITNAME = MessageManager.getString("label.edit_label_description");
 
-  static String HIDE = "Hide This Row";
+  String HIDE = MessageManager.getString("label.hide_row");
 
-  static String DELETE = "Delete This Row";
+  String DELETE = MessageManager.getString("label.delete_row");
 
-  static String SHOWALL = "Show All Hidden Rows";
+  String SHOWALL = MessageManager.getString("label.show_all_hidden_rows");
 
-  static String OUTPUT_TEXT = "Export Annotation";
+  String OUTPUT_TEXT = MessageManager.getString("label.export_annotation");
 
-  static String COPYCONS_SEQ = "Copy Consensus Sequence";
+  String COPYCONS_SEQ = MessageManager.getString("label.copy_consensus_sequence");
 
   boolean resizePanel = false;
 
index 73be63e..4adeb83 100755 (executable)
@@ -42,20 +42,20 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
         MouseListener, MouseWheelListener, MouseMotionListener,
         ActionListener, AdjustmentListener, Scrollable
 {
-  final String HELIX = "Helix";
+  String HELIX = MessageManager.getString("label.helix");
 
-  final String SHEET = "Sheet";
+  String SHEET = MessageManager.getString("label.sheet");
 
   /**
    * For RNA secondary structure "stems" aka helices
    */
-  final String STEM = "RNA Helix";
+  String STEM = MessageManager.getString("label.rna_helix");
 
-  final String LABEL = "Label";
+  String LABEL = MessageManager.getString("label.label");
 
-  final String REMOVE = "Remove Annotation";
+  String REMOVE = MessageManager.getString("label.remove_annotation");
 
-  final String COLOUR = "Colour";
+  String COLOUR = MessageManager.getString("action.colour");
 
   public final Color HELIX_COLOUR = Color.red.darker();
 
@@ -307,7 +307,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
     else if (evt.getActionCommand().equals(COLOUR))
     {
       Color col = JColorChooser.showDialog(this,
-              "Choose foreground colour", Color.black);
+              MessageManager.getString("label.select_foreground_colour"), Color.black);
 
       for (int i = 0; i < av.getColumnSelection().size(); i++)
       {
@@ -673,10 +673,8 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
               && aa[row].annotations[res].description != null
               && aa[row].annotations[res].description.length() > 0)
       {
-        this.setToolTipText("<html>"
-                + JvSwingUtils
-                        .wrapTooltip(aa[row].annotations[res].description)
-                + "</html>");
+        this.setToolTipText(JvSwingUtils
+                        .wrapTooltip(true, aa[row].annotations[res].description));
       }
       else
       {
index bcdc2de..998db4b 100644 (file)
@@ -177,7 +177,7 @@ public class AppJmol extends GStructureViewer implements Runnable,
       _alignwith = new Vector<AlignmentPanel>();
     }
 
-    seqColourBy = new ViewSelectionMenu("Colour by ..", this, _colourwith,
+    seqColourBy = new ViewSelectionMenu(MessageManager.getString("label.colour_by"), this, _colourwith,
             new ItemListener()
             {
 
@@ -197,7 +197,7 @@ public class AppJmol extends GStructureViewer implements Runnable,
             });
     viewMenu.add(seqColourBy);
     final ItemListener handler;
-    JMenu alpanels = new ViewSelectionMenu("Superpose with ..", this,
+    JMenu alpanels = new ViewSelectionMenu(MessageManager.getString("label.superpose_with"), this,
             _alignwith, handler = new ItemListener()
             {
 
@@ -731,7 +731,7 @@ public class AppJmol extends GStructureViewer implements Runnable,
           long hdl = pdbid.hashCode() - System.currentTimeMillis();
           if (progressBar != null)
           {
-            progressBar.setProgressBar("Fetching PDB " + pdbid, hdl);
+            progressBar.setProgressBar(MessageManager.formatMessage("status.fetching_pdb", new String[]{pdbid}), hdl);
           }
           try
           {
@@ -747,7 +747,7 @@ public class AppJmol extends GStructureViewer implements Runnable,
           }
           if (progressBar != null)
           {
-            progressBar.setProgressBar("Finished.", hdl);
+            progressBar.setProgressBar(MessageManager.getString("label.state_completed"), hdl);
           }
           if (pdbseq != null)
           {
@@ -891,7 +891,7 @@ public class AppJmol extends GStructureViewer implements Runnable,
             jalview.bin.Cache.getProperty("LAST_DIRECTORY"));
 
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save PDB File");
+    chooser.setDialogTitle(MessageManager.getString("label.save_pdb_file"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
@@ -1096,7 +1096,7 @@ public class AppJmol extends GStructureViewer implements Runnable,
   public void backGround_actionPerformed(ActionEvent actionEvent)
   {
     java.awt.Color col = JColorChooser.showDialog(this,
-            "Select Background Colour", null);
+            MessageManager.getString("label.select_backgroud_colour"), null);
     if (col != null)
     {
       jmb.setBackgroundColour(col);
index 0935d9f..7a1065d 100644 (file)
@@ -331,7 +331,7 @@ public class BlogReader extends JPanel
         {
           createDialog();
           bounds = new Rectangle(5, 5, 550, 350);
-          jd.initDialogFrame(me, false, false, "News from www.jalview.org",
+          jd.initDialogFrame(me, false, false, MessageManager.getString("label.news_from_jalview"),
                   bounds.width, bounds.height);
           jd.frame.setModalExclusionType(ModalExclusionType.NO_EXCLUDE);
           Cache.log.info("Displaying news.");
@@ -440,7 +440,7 @@ public class BlogReader extends JPanel
     topBottomSplitPane.setBottomComponent(bottomPanel);
     JScrollPane spTextDescription = new JScrollPane(textDescription);
     textDescription.setText("");
-    statusBar.setText(MessageManager.getString("label.status"));
+    statusBar.setText(new StringBuffer("[").append(MessageManager.getString("label.status")).append("]").toString());
     buttonRefresh.addActionListener(new ActionListener()
     {
 
index 10082eb..236d094 100644 (file)
@@ -154,7 +154,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
       _alignwith = new Vector<AlignmentPanel>();
     }
 
-    seqColourBy = new ViewSelectionMenu("Colour by ..", this, _colourwith,
+    seqColourBy = new ViewSelectionMenu(MessageManager.getString("label.colour_by"), this, _colourwith,
             new ItemListener()
             {
 
@@ -174,7 +174,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
             });
     viewMenu.add(seqColourBy);
     final ItemListener handler;
-    JMenu alpanels = new ViewSelectionMenu("Superpose with ..", this,
+    JMenu alpanels = new ViewSelectionMenu(MessageManager.getString("label.superpose_with"), this,
             _alignwith, handler = new ItemListener()
             {
 
@@ -698,7 +698,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
           long hdl = pdbid.hashCode() - System.currentTimeMillis();
           if (progressBar != null)
           {
-            progressBar.setProgressBar("Fetching PDB " + pdbid, hdl);
+            progressBar.setProgressBar(MessageManager.formatMessage("status.fetching_pdb", new String[]{pdbid}), hdl);
           }
           try
           {
@@ -714,7 +714,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
           }
           if (progressBar != null)
           {
-            progressBar.setProgressBar("Finished.", hdl);
+            progressBar.setProgressBar(MessageManager.getString("label.state_completed"), hdl);
           }
           if (pdbseq != null)
           {
@@ -866,7 +866,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
             jalview.bin.Cache.getProperty("LAST_DIRECTORY"));
 
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save PDB File");
+    chooser.setDialogTitle(MessageManager.getString("label.save_pdb_file"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
@@ -928,7 +928,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
    */
   public void eps_actionPerformed(ActionEvent e)
   {
-    throw new Error("EPS Generation not yet implemented.");
+    throw new Error(MessageManager.getString("error.eps_generation_not_implemented"));
   }
 
   /**
@@ -939,7 +939,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
    */
   public void png_actionPerformed(ActionEvent e)
   {
-    throw new Error("PNG Generation not yet implemented.");
+           throw new Error(MessageManager.getString("error.png_generation_not_implemented"));
   }
 
   public void jmolColour_actionPerformed(ActionEvent actionEvent)
@@ -1044,7 +1044,7 @@ public class ChimeraViewFrame extends GStructureViewer implements Runnable,
   public void backGround_actionPerformed(ActionEvent actionEvent)
   {
     java.awt.Color col = JColorChooser.showDialog(this,
-            "Select Background Colour", null);
+               MessageManager.getString("label.select_backgroud_colour"), null);
     if (col != null)
     {
       jmb.setBackgroundColour(col);
index 5f06bad..ea7e539 100644 (file)
@@ -501,8 +501,7 @@ public class Console extends WindowAdapter implements WindowListener,
       } catch (InterruptedException ie)
       {
       }
-      throw new NullPointerException(
-              "Application test: throwing an NullPointerException It should arrive at the console");
+      throw new NullPointerException(MessageManager.getString("exception.application_test_npe"));
     }
   }
 
index 74297bb..7fd091f 100644 (file)
@@ -141,7 +141,7 @@ public class CutAndPasteHtmlTransfer extends GCutAndPasteHtmlTransfer
 
     chooser.setAcceptAllFileFilterUsed(false);
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save Text to File");
+    chooser.setDialogTitle(MessageManager.getString("label.save_text_to_file"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
index 7f8d289..0c22b14 100644 (file)
@@ -100,7 +100,7 @@ public class CutAndPasteTransfer extends GCutAndPasteTransfer
 
     chooser.setAcceptAllFileFilterUsed(false);
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save Text to File");
+    chooser.setDialogTitle(MessageManager.getString("label.save_text_to_file"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
index b8dd645..779e82f 100644 (file)
@@ -741,7 +741,7 @@ public class DasSourceBrowser extends GDasSourceBrowser implements
     }
 
     private String[] columnNames = new String[]
-    { "Nickname", "Use Source" };
+    { MessageManager.getString("label.nickname"), MessageManager.getString("label.use_source") };
 
     private Object[][] data;
 
index b7057d1..123aed2 100644 (file)
@@ -452,7 +452,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
           public void run()
           {
             long instance = System.currentTimeMillis();
-            Desktop.instance.setProgressBar("Refreshing news", instance);
+            Desktop.instance.setProgressBar(MessageManager.getString("status.refreshing_news"), instance);
             jvnews.refreshNews();
             Desktop.instance.setProgressBar(null, instance);
             jvnews.showNews();
@@ -1012,7 +1012,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
       if (format.equals("URL NOT FOUND"))
       {
         JOptionPane.showInternalMessageDialog(Desktop.desktop,
-                "Couldn't locate " + url, "URL not found",
+                MessageManager.formatMessage("label.couldnt_locate", new String[]{url}), MessageManager.getString("label.url_not_found"),
                 JOptionPane.WARNING_MESSAGE);
 
         return;
@@ -1039,7 +1039,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
   {
     CutAndPasteTransfer cap = new CutAndPasteTransfer();
     cap.setForInput(viewport);
-    Desktop.addInternalFrame(cap, "Cut & Paste Alignment File", 600, 500);
+    Desktop.addInternalFrame(cap, MessageManager.getString("label.cut_paste_alignmen_file"), 600, 500);
   }
 
   /*
@@ -1386,7 +1386,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
             { "Jalview Project" }, "Jalview Project");
 
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save State");
+    chooser.setDialogTitle(MessageManager.getString("label.save_state"));
 
     int value = chooser.showSaveDialog(this);
 
@@ -1399,7 +1399,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
         public void run()
         {
 
-          setProgressBar("Saving jalview project " + choice.getName(),
+          setProgressBar(MessageManager.formatMessage("label.saving_jalview_project", new String[]{choice.getName()}),
                   choice.hashCode());
           jalview.bin.Cache.setProperty("LAST_DIRECTORY",
                   choice.getParent());
@@ -1419,8 +1419,8 @@ public class Desktop extends jalview.jbgui.GDesktop implements
                     ex);
             JOptionPane.showMessageDialog(
                     me,
-                    "Error whilst saving current state to "
-                            + choice.getName(), "Couldn't save project",
+                    MessageManager.formatMessage("label.error_whilst_saving_current_state_to", new String[]{ choice.getName()}),
+                    MessageManager.getString("label.couldnt_save_project"),
                     JOptionPane.WARNING_MESSAGE);
           }
           setProgressBar(null, choice.hashCode());
@@ -1443,7 +1443,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
             { "Jalview Project", "Jalview Project (old)" },
             "Jalview Project");
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Restore state");
+    chooser.setDialogTitle(MessageManager.getString("label.restore_state"));
 
     int value = chooser.showOpenDialog(this);
 
@@ -1456,7 +1456,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
       {
         public void run()
         {
-          setProgressBar("loading jalview project " + choice,
+          setProgressBar(MessageManager.formatMessage("label.loading_jalview_project", new String[]{choice}),
                   choice.hashCode());
           try
           {
@@ -1469,8 +1469,8 @@ public class Desktop extends jalview.jbgui.GDesktop implements
             Cache.log.error("Problems whilst loading project from "
                     + choice, ex);
             JOptionPane.showMessageDialog(Desktop.desktop,
-                    "Error whilst loading project from " + choice,
-                    "Couldn't load project", JOptionPane.WARNING_MESSAGE);
+                       MessageManager.formatMessage("label.error_whilst_loading_project_from", new String[]{choice}),
+                    MessageManager.getString("label.couldnt_load_project"), JOptionPane.WARNING_MESSAGE);
           }
           setProgressBar(null, choice.hashCode());
         }
@@ -1491,8 +1491,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
   {
     if (fileLoadingCount == 0)
     {
-      fileLoadingPanels.add(addProgressPanel("Loading File: " + fileName
-              + "   "));
+      fileLoadingPanels.add(addProgressPanel(MessageManager.formatMessage("label.loading_file", new String[]{fileName})));
     }
     fileLoadingCount++;
   }
@@ -1730,7 +1729,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
               jalview.bin.Cache.getProperty("LAST_DIRECTORY"));
 
       chooser.setFileView(new JalviewFileView());
-      chooser.setDialogTitle("Open a saved VAMSAS session");
+      chooser.setDialogTitle(MessageManager.getString("label.open_saved_vamsas_session"));
       chooser.setToolTipText(MessageManager
               .getString("label.select_vamsas_session_opened_as_new_vamsas_session"));
 
@@ -1823,22 +1822,22 @@ public class Desktop extends jalview.jbgui.GDesktop implements
       return false;
     }
 
-    setProgressBar("Importing VAMSAS session from " + file.getName(),
+    setProgressBar(MessageManager.formatMessage("status.importing_vamsas_session_from", new String[]{file.getName()}),
             file.hashCode());
     try
     {
       v_client = new jalview.gui.VamsasApplication(this, file, null);
     } catch (Exception ex)
     {
-      setProgressBar("Importing VAMSAS session from " + file.getName(),
-              file.hashCode());
+        setProgressBar(MessageManager.formatMessage("status.importing_vamsas_session_from", new String[]{file.getName()}),
+                file.hashCode());
       jalview.bin.Cache.log.error(
               "New vamsas session from existing session file failed:", ex);
       return false;
     }
     setupVamsasConnectedGui();
     v_client.initial_update(); // TODO: thread ?
-    setProgressBar("Importing VAMSAS session from " + file.getName(),
+    setProgressBar(MessageManager.formatMessage("status.importing_vamsas_session_from", new String[]{file.getName()}),
             file.hashCode());
     return v_client.inSession();
   }
@@ -1847,12 +1846,11 @@ public class Desktop extends jalview.jbgui.GDesktop implements
   {
     if (v_client != null)
     {
-      throw new Error(
-              "Trying to join a vamsas session when another is already connected.");
+      throw new Error(MessageManager.getString("error.try_join_vamsas_session_another"));
     }
     if (mysesid == null)
     {
-      throw new Error("Invalid vamsas session id.");
+      throw new Error(MessageManager.getString("error.invalid_vamsas_session_id"));
     }
     v_client = new VamsasApplication(this, mysesid);
     setupVamsasConnectedGui();
@@ -1999,15 +1997,14 @@ public class Desktop extends jalview.jbgui.GDesktop implements
               { "Vamsas Document" }, "Vamsas Document");
 
       chooser.setFileView(new JalviewFileView());
-      chooser.setDialogTitle("Save Vamsas Document Archive");
+      chooser.setDialogTitle(MessageManager.getString("label.save_vamsas_document_archive"));
 
       int value = chooser.showSaveDialog(this);
 
       if (value == JalviewFileChooser.APPROVE_OPTION)
       {
         java.io.File choice = chooser.getSelectedFile();
-        JPanel progpanel = addProgressPanel("Saving VAMSAS Document to "
-                + choice.getName());
+        JPanel progpanel = addProgressPanel(MessageManager.formatMessage("label.saving_vamsas_doc", new String[]{choice.getName()}));
         jalview.bin.Cache.setProperty("LAST_DIRECTORY", choice.getParent());
         String warnmsg = null;
         String warnttl = null;
@@ -2059,7 +2056,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
     }
     if (b)
     {
-      vamUpdate = this.addProgressPanel("Updating vamsas session");
+      vamUpdate = this.addProgressPanel(MessageManager.getString("label.updating_vamsas_session"));
     }
     vamsasStart.setVisible(!b);
     vamsasStop.setVisible(!b);
@@ -2290,8 +2287,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
     // use reflection to avoid creating compilation dependency.
     if (!jalview.bin.Cache.groovyJarsPresent())
     {
-      throw new Error(
-              "Implementation Error. Cannot create groovyShell without Groovy on the classpath!");
+      throw new Error(MessageManager.getString("error.implementation_error_cannot_create_groovyshell"));
     }
     try
     {
@@ -2313,8 +2309,8 @@ public class Desktop extends jalview.jbgui.GDesktop implements
               .showInternalMessageDialog(
                       Desktop.desktop,
 
-                      "Couldn't create the groovy Shell. Check the error log for the details of what went wrong.",
-                      "Jalview Groovy Support Failed",
+                      MessageManager.getString("label.couldnt_create_groovy_shell"),
+                      MessageManager.getString("label.groovy_support_failed"),
                       JOptionPane.ERROR_MESSAGE);
     }
   }
@@ -2365,8 +2361,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
   {
     if (progressBarHandlers == null || !progressBars.contains(new Long(id)))
     {
-      throw new Error(
-              "call setProgressBar before registering the progress bar's handler.");
+      throw new Error(MessageManager.getString("error.call_setprogressbar_before_registering_handler"));
     }
     progressBarHandlers.put(new Long(id), handler);
     final JPanel progressPanel = (JPanel) progressBars.get(new Long(id));
@@ -2381,10 +2376,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
         public void actionPerformed(ActionEvent e)
         {
           handler.cancelActivity(id);
-          us.setProgressBar(
-                  "Cancelled "
-                          + ((JLabel) progressPanel.getComponent(0))
-                                  .getText(), id);
+          us.setProgressBar(MessageManager.formatMessage("label.cancelled_params", new String[]{((JLabel) progressPanel.getComponent(0)).getText()}), id);
         }
       });
       progressPanel.add(cancel, BorderLayout.EAST);
@@ -2646,7 +2638,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
         {
           if (progress != null)
           {
-            progress.setProgressBar("Opening " + url, this.hashCode());
+            progress.setProgressBar(MessageManager.formatMessage("status.opening_params", new String[]{url}), this.hashCode());
           }
           jalview.util.BrowserLauncher.openURL(url);
         } catch (Exception ex)
@@ -2654,9 +2646,8 @@ public class Desktop extends jalview.jbgui.GDesktop implements
           JOptionPane
                   .showInternalMessageDialog(
                           Desktop.desktop,
-                          "Unixers: Couldn't find default web browser."
-                                  + "\nAdd the full path to your browser in Preferences.",
-                          "Web browser not found",
+                          MessageManager.getString("label.web_browser_not_found_unix"),
+                          MessageManager.getString("label.web_browser_not_found"),
                           JOptionPane.WARNING_MESSAGE);
 
           ex.printStackTrace();
index eb64dee..d2d9c9c 100644 (file)
@@ -940,8 +940,7 @@ public class FeatureRenderer implements jalview.api.FeatureRenderer
         return ((GraduatedColor) fc).getMaxColor();
       }
     }
-    throw new Error("Implementation Error: Unrecognised render object "
-            + fc.getClass() + " for features of type " + featureType);
+    throw new Error(MessageManager.formatMessage("error.implementation_error_unrecognised_render_object_for_features_type", new String[]{fc.getClass().toString(),featureType}));
   }
 
   /**
@@ -965,8 +964,7 @@ public class FeatureRenderer implements jalview.api.FeatureRenderer
         return ((GraduatedColor) fc).findColor(feature);
       }
     }
-    throw new Error("Implementation Error: Unrecognised render object "
-            + fc.getClass() + " for features of type " + feature.getType());
+    throw new Error(MessageManager.formatMessage("error.implementation_error_unrecognised_render_object_for_features_type", new String[]{fc.getClass().toString(),feature.getType()}));
   }
 
   private boolean showFeature(SequenceFeature sequenceFeature)
@@ -1026,7 +1024,7 @@ public class FeatureRenderer implements jalview.api.FeatureRenderer
         if (fcol instanceof Color)
         {
           Color col = JColorChooser.showDialog(Desktop.desktop,
-                  "Select Feature Colour", ((Color) fcol));
+                  MessageManager.getString("label.select_feature_colour"), ((Color) fcol));
           if (col != null)
           {
             fcol = col;
@@ -1218,12 +1216,12 @@ public class FeatureRenderer implements jalview.api.FeatureRenderer
       { "OK", "Cancel" };
     }
 
-    String title = newFeatures ? "Create New Sequence Feature(s)"
-            : "Amend/Delete Features for " + sequences[0].getName();
+    String title = newFeatures ? MessageManager.getString("label.create_new_sequence_features")
+            : MessageManager.formatMessage("label.amend_delete_features", new String[]{sequences[0].getName()});
 
     int reply = JOptionPane.showInternalOptionDialog(Desktop.desktop,
             bigPanel, title, JOptionPane.YES_NO_CANCEL_OPTION,
-            JOptionPane.QUESTION_MESSAGE, null, options, "OK");
+            JOptionPane.QUESTION_MESSAGE, null, options, MessageManager.getString("action.ok"));
 
     jalview.io.FeaturesFile ffile = new jalview.io.FeaturesFile();
 
index 3dae4e5..304d352 100644 (file)
@@ -141,10 +141,8 @@ public class FeatureSettings extends JPanel
         }
       }
     });
-    table.setToolTipText("<html>"
-            + JvSwingUtils
-                    .wrapTooltip("Click/drag feature types up or down to change render order.<br/>Double click to select columns containing feature in alignment/current selection<br/>Pressing Alt will select columns outside features rather than inside<br/>Pressing Shift to modify current selection (rather than clear current selection)<br/>Press CTRL or Command/Meta to toggle columns in/outside features<br/>")
-            + "</html>");
+    table.setToolTipText(JvSwingUtils
+                    .wrapTooltip(true, MessageManager.getString("label.feature_settings_click_drag")));
     scrollPane.setViewportView(table);
 
     dassourceBrowser = new DasSourceBrowser(this);
@@ -648,7 +646,7 @@ public class FeatureSettings extends JPanel
             { "fc" }, new String[]
             { "Sequence Feature Colours" }, "Sequence Feature Colours");
     chooser.setFileView(new jalview.io.JalviewFileView());
-    chooser.setDialogTitle("Load Feature Colours");
+    chooser.setDialogTitle(MessageManager.getString("label.load_feature_colours"));
     chooser.setToolTipText(MessageManager.getString("action.load"));
 
     int value = chooser.showOpenDialog(this);
@@ -746,7 +744,7 @@ public class FeatureSettings extends JPanel
             { "fc" }, new String[]
             { "Sequence Feature Colours" }, "Sequence Feature Colours");
     chooser.setFileView(new jalview.io.JalviewFileView());
-    chooser.setDialogTitle("Save Feature Colour Scheme");
+    chooser.setDialogTitle(MessageManager.getString("label.save_feature_colours"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
@@ -1064,8 +1062,8 @@ public class FeatureSettings extends JPanel
       }
     });
     this.add(tabbedPane, java.awt.BorderLayout.CENTER);
-    tabbedPane.addTab("Feature Settings", settingsPane);
-    tabbedPane.addTab("DAS Settings", dasSettingsPane);
+    tabbedPane.addTab(MessageManager.getString("label.feature_settings"), settingsPane);
+    tabbedPane.addTab(MessageManager.getString("label.das_settings"), dasSettingsPane);
     bigPanel.add(transPanel, java.awt.BorderLayout.SOUTH);
     transbuttons.add(optimizeOrder);
     transbuttons.add(invert);
@@ -1382,7 +1380,7 @@ public class FeatureSettings extends JPanel
     }
 
     private String[] columnNames =
-    { "Feature Type", "Colour", "Display" };
+    { MessageManager.getString("label.feature_type"), MessageManager.getString("action.colour"), MessageManager.getString("label.display") };
 
     private Object[][] data;
 
index cda6c46..b6116d9 100755 (executable)
@@ -226,8 +226,8 @@ public class FontChooser extends GFontChooser
       JOptionPane
               .showInternalMessageDialog(
                       this,
-                      "Font doesn't have letters defined\nso cannot be used\nwith alignment data.",
-                      "Invalid Font", JOptionPane.WARNING_MESSAGE);
+                      MessageManager.getString("label.font_doesnt_have_letters_defined"),
+                      MessageManager.getString("label.invalid_font"), JOptionPane.WARNING_MESSAGE);
       return;
     }
     if (tp != null)
index ee779f7..39afd2c 100755 (executable)
@@ -29,6 +29,7 @@ import javax.swing.*;
 
 import jalview.datamodel.*;
 import jalview.io.SequenceAnnotationReport;
+import jalview.util.MessageManager;
 import jalview.util.UrlLink;
 
 /**
@@ -226,9 +227,8 @@ public class IdPanel extends JPanel implements MouseListener,
       JOptionPane
               .showInternalMessageDialog(
                       Desktop.desktop,
-                      "Unixers: Couldn't find default web browser."
-                              + "\nAdd the full path to your browser in Preferences.",
-                      "Web browser not found", JOptionPane.WARNING_MESSAGE);
+                      MessageManager.getString("label.web_browser_not_found_unix"),
+                      MessageManager.getString("label.web_browser_not_found"), JOptionPane.WARNING_MESSAGE);
       ex.printStackTrace();
     }
 
index 43f5333..030e78a 100644 (file)
@@ -86,7 +86,7 @@ public class JDatabaseTree extends JalviewDialog implements KeyListener
 
   public JDatabaseTree(jalview.ws.SequenceFetcher sfetch)
   {
-    initDialogFrame(this, true, false, "Select Database Retrieval Source",
+    initDialogFrame(this, true, false, MessageManager.getString("label.select_database_retrieval_source"),
             650, 490);
     /*
      * Dynamically generated database list will need a translation function from
@@ -219,8 +219,7 @@ public class JDatabaseTree extends JalviewDialog implements KeyListener
       }
       else
       {
-        throw new Error(
-                "Implementation Error: Can't reorder this tree. Not DefaultMutableTreeNode.");
+        throw new Error(MessageManager.getString("error.implementation_error_cant_reorder_tree"));
       }
     }
     jalview.util.QuickSort.sort(names, nodes);
index f3bc42e..105209f 100644 (file)
@@ -40,6 +40,7 @@ import jalview.datamodel.AlignmentI;
 import jalview.datamodel.SequenceI;
 import jalview.schemabinding.version2.*;
 import jalview.schemes.*;
+import jalview.util.MessageManager;
 import jalview.util.Platform;
 import jalview.util.jarInputStreamProvider;
 import jalview.viewmodel.AlignmentViewport;
@@ -437,7 +438,7 @@ public class Jalview2XML
     for (String dssids : dsses.keySet())
     {
       AlignFrame _af = dsses.get(dssids);
-      String jfileName = fileName + " Dataset for " + _af.getTitle();
+      String jfileName = MessageManager.formatMessage("label.dataset_for", new String[]{fileName,_af.getTitle()});
       if (!jfileName.endsWith(".xml"))
       {
         jfileName = jfileName + ".xml";
@@ -1502,8 +1503,7 @@ public class Jalview2XML
         return false;
       }
     }
-    throw new Error("Unsupported Version for calcIdparam "
-            + calcIdParam.toString());
+    throw new Error(MessageManager.formatMessage("error.unsupported_version_calcIdparam", new String[]{calcIdParam.toString()}));
   }
 
   /**
index 2e3b236..946181c 100755 (executable)
@@ -160,7 +160,7 @@ public class Jalview2XML_V1
           {
 
             JOptionPane.showInternalMessageDialog(Desktop.desktop,
-                    "Error loading  " + file, "Error loading Jalview file",
+                    MessageManager.formatMessage("label.error_loading_file_params", new String[]{file}), MessageManager.getString("label.error_loading_jalview_file"),
                     JOptionPane.WARNING_MESSAGE);
           }
         });
index 4dfd40d..d546584 100644 (file)
@@ -46,20 +46,22 @@ public final class JvSwingUtils
    * <table width=350>
    * <tr>
    * <td></td> field
+ * @param enclose TODO
+ * @param ttext
    * 
-   * @param ttext
    * @return
    */
-  public static String wrapTooltip(String ttext)
+  public static String wrapTooltip(boolean enclose, String ttext)
   {
+         
     if (ttext.length() < 60)
     {
-      return ttext;
+      return enclose ? "<html>"+ttext+"</html>" : ttext;
     }
     else
     {
-      return "<table width=350 border=0><tr><td>" + ttext
-              + "</td></tr></table>";
+      return (enclose ? "<html>" : "") + "<table width=350 border=0><tr><td>" + ttext
+              + "</td></tr></table>" + ((enclose ? "</html>" : ""));
     }
   }
 
index 8a61757..a9347eb 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.gui;
 
+import jalview.util.MessageManager;
+
 import java.awt.Component;
 
 public class OOMWarning implements Runnable
@@ -78,11 +80,8 @@ public class OOMWarning implements Runnable
     javax.swing.JOptionPane
             .showInternalMessageDialog(
                     desktop,
-                    "Out of memory when "
-                            + action
-                            + "!!"
-                            + "\nSee help files for increasing Java Virtual Machine memory.",
-                    "Out of memory",
+                    MessageManager.formatMessage("warn.out_of_memory_when_action", new String[]{action}),
+                    MessageManager.getString("label.out_of_memory"),
                     javax.swing.JOptionPane.WARNING_MESSAGE);
     // hope that there's enough memory left that no more appear.
     oomInprogress = false;
index 847c26a..78ddb3f 100644 (file)
@@ -111,21 +111,21 @@ public class OptsAndParamsPage
       {
         hasLink = true;
 
-        enabled.setToolTipText("<html>"
-                + JvSwingUtils
-                        .wrapTooltip(((desc == null || desc.trim().length() == 0) ? "see further details by right-clicking"
+        enabled.setToolTipText(
+             JvSwingUtils
+                        .wrapTooltip(true, ((desc == null || desc.trim().length() == 0) ? MessageManager.getString("label.opt_and_params_further_details ")
                                 : desc)
                                 + "<br><img src=\"" + linkImageURL + "\"/>")
-                + "</html>");
+                );
         enabled.addMouseListener(this);
       }
       else
       {
         if (desc != null && desc.trim().length() > 0)
         {
-          enabled.setToolTipText("<html>"
-                  + JvSwingUtils.wrapTooltip(opt.getDescription())
-                  + "</html>");
+          enabled.setToolTipText(
+                   JvSwingUtils.wrapTooltip(true, opt.getDescription())
+                 );
         }
       }
       add(enabled, BorderLayout.NORTH);
@@ -344,13 +344,12 @@ public class OptsAndParamsPage
               && parm.getDescription().trim().length() > 0)
       {
         // Only create description boxes if there actually is a description.
-        ttipText = ("<html>"
-                + JvSwingUtils
-                        .wrapTooltip(parm.getDescription()
+        ttipText = (JvSwingUtils
+                        .wrapTooltip(true, parm.getDescription()
                                 + (finfo != null ? "<br><img src=\""
                                         + linkImageURL
-                                        + "\"/> Right click for further information."
-                                        : "")) + "</html>");
+                                        + "\"/>"+MessageManager.getString("label.opt_and_params_further_detail")
+                                        : "")));
       }
 
       JvSwingUtils.mgAddtoLayout(this, ttipText,
@@ -391,20 +390,12 @@ public class OptsAndParamsPage
         // Only create description boxes if there actually is a description.
         if (finfo != null)
         {
-          showDesc.setToolTipText("<html>"
-                  + JvSwingUtils
-                          .wrapTooltip("Click to show brief description<br><img src=\""
-                                  + linkImageURL
-                                  + "\"/> Right click for further information.")
-                  + "</html>");
+          showDesc.setToolTipText(JvSwingUtils.wrapTooltip(false, MessageManager.formatMessage("label.opt_and_params_show_brief_desc_image_link", new String[]{linkImageURL.toExternalForm()})));
           showDesc.addMouseListener(this);
         }
         else
         {
-          showDesc.setToolTipText("<html>"
-                  + JvSwingUtils
-                          .wrapTooltip("Click to show brief description.")
-                  + "</html>");
+          showDesc.setToolTipText(JvSwingUtils.wrapTooltip(false, MessageManager.getString("label.opt_and_params_show_brief_desc")));
         }
         showDesc.addActionListener(new ActionListener()
         {
@@ -863,7 +854,7 @@ public class OptsAndParamsPage
       }
       else
       {
-        throw new Error("Invalid value " + string + " for option " + option);
+        throw new Error(MessageManager.formatMessage("error.invalid_value_for_option", new String[]{string,option.getName()}));
       }
 
     }
index f07993c..3483cc4 100644 (file)
@@ -97,10 +97,8 @@ public class PCAPanel extends GPCAPanel implements Runnable,
       JOptionPane
               .showMessageDialog(
                       Desktop.desktop,
-                      "The sequences must be aligned before calculating PCA.\n"
-                              + "Try using the Pad function in the edit menu,\n"
-                              + "or one of the multiple sequence alignment web services.",
-                      "Sequences not aligned", JOptionPane.WARNING_MESSAGE);
+                      MessageManager.getString("label.pca_sequences_not_aligned"),
+                      MessageManager.getString("label.sequences_not_aligned"), JOptionPane.WARNING_MESSAGE);
 
       return;
     }
@@ -153,7 +151,7 @@ public class PCAPanel extends GPCAPanel implements Runnable,
 
   public void bgcolour_actionPerformed(ActionEvent e)
   {
-    Color col = JColorChooser.showDialog(this, "Select Background Colour",
+    Color col = JColorChooser.showDialog(this, MessageManager.getString("label.select_backgroud_colour"),
             rc.bgColour);
 
     if (col != null)
@@ -170,11 +168,11 @@ public class PCAPanel extends GPCAPanel implements Runnable,
   {
     long progId = System.currentTimeMillis();
     IProgressIndicator progress = this;
-    String message = "Recalculating PCA";
+    String message = MessageManager.getString("label.pca_recalculating");
     if (getParent() == null)
     {
       progress = ap.alignFrame;
-      message = "Calculating PCA";
+      message = MessageManager.getString("label.pca_calculating");
     }
     progress.setProgressBar(message, progId);
     try
@@ -668,8 +666,7 @@ public class PCAPanel extends GPCAPanel implements Runnable,
   {
     if (progressBarHandlers == null || !progressBars.contains(new Long(id)))
     {
-      throw new Error(
-              "call setProgressBar before registering the progress bar's handler.");
+      throw new Error(MessageManager.getString("error.call_setprogressbar_before_registering_handler"));
     }
     progressBarHandlers.put(new Long(id), handler);
     final JPanel progressPanel = (JPanel) progressBars.get(new Long(id));
@@ -685,10 +682,7 @@ public class PCAPanel extends GPCAPanel implements Runnable,
         public void actionPerformed(ActionEvent e)
         {
           handler.cancelActivity(id);
-          us.setProgressBar(
-                  "Cancelled "
-                          + ((JLabel) progressPanel.getComponent(0))
-                                  .getText(), id);
+          us.setProgressBar(MessageManager.formatMessage("label.cancelled_params", new String[]{((JLabel) progressPanel.getComponent(0)).getText()}), id);
         }
       });
       progressPanel.add(cancel, BorderLayout.EAST);
index 4f52f52..e44915d 100755 (executable)
@@ -213,11 +213,10 @@ public class Preferences extends GPreferences
     sortby.addItem("Pairwise Identity");
     sortby.setSelectedItem(Cache.getDefault("SORT_ALIGNMENT", "No sort"));
 
-    epsRendering.addItem("Prompt each time");
-    epsRendering.addItem("Lineart");
-    epsRendering.addItem("Text");
-    epsRendering.setSelectedItem(Cache.getDefault("EPS_RENDERING",
-            "Prompt each time"));
+    epsRendering.addItem(MessageManager.getString("label.prompt_each_time"));
+    epsRendering.addItem(MessageManager.getString("label.lineart"));
+    epsRendering.addItem(MessageManager.getString("action.text"));
+    epsRendering.setSelectedIndex(0);
     autoIdWidth.setSelected(Cache.getDefault("FIGURE_AUTOIDWIDTH", false));
     userIdWidth.setEnabled(autoIdWidth.isSelected());
     userIdWidthlabel.setEnabled(autoIdWidth.isSelected());
@@ -510,7 +509,7 @@ public class Preferences extends GPreferences
             { "Fasta", "Clustal", "PFAM", "MSF", "PIR", "BLC", "Jalview" },
             jalview.bin.Cache.getProperty("DEFAULT_FILE_FORMAT"));
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Select startup file");
+    chooser.setDialogTitle(MessageManager.getString("label.select_startup_file"));
 
     int value = chooser.showOpenDialog(this);
 
@@ -652,7 +651,7 @@ public class Preferences extends GPreferences
   public void defaultBrowser_mouseClicked(MouseEvent e)
   {
     JFileChooser chooser = new JFileChooser(".");
-    chooser.setDialogTitle("Select default web browser");
+    chooser.setDialogTitle(MessageManager.getString("label.select_default_browser"));
 
     int value = chooser.showOpenDialog(this);
 
@@ -688,7 +687,7 @@ public class Preferences extends GPreferences
   public void minColour_actionPerformed()
   {
     Color col = JColorChooser.showDialog(this,
-            "Select Colour for Minimum Value", minColour.getBackground());
+            MessageManager.getString("label.select_colour_minimum_value"), minColour.getBackground());
     if (col != null)
     {
       minColour.setBackground(col);
@@ -699,7 +698,7 @@ public class Preferences extends GPreferences
   public void maxColour_actionPerformed()
   {
     Color col = JColorChooser.showDialog(this,
-            "Select Colour for Maximum Value", maxColour.getBackground());
+            MessageManager.getString("label.select_colour_maximum_value"), maxColour.getBackground());
     if (col != null)
     {
       maxColour.setBackground(col);
@@ -727,8 +726,8 @@ public class Preferences extends GPreferences
       JOptionPane
               .showInternalMessageDialog(
                       Desktop.desktop,
-                      "The user defined width for the\nannotation and sequence ID columns\nin exported figures must be\nat least 12 pixels wide.",
-                      "Invalid ID Column width",
+                      MessageManager.getString("warn.user_defined_width_requirements"),
+                      MessageManager.getString("label.invalid_id_column_width"),
                       JOptionPane.WARNING_MESSAGE);
       userIdWidth.setText("");
     }
index 5adfae9..1fcd875 100755 (executable)
@@ -159,7 +159,7 @@ public class RedundancyPanel extends GSliderPanel implements Runnable
     progress.setVisible(false);
     progress = null;
 
-    label.setText("Enter the redundancy threshold");
+    label.setText(MessageManager.getString("label.enter_redundancy_thereshold"));
     slider.setVisible(true);
     applyButton.setEnabled(true);
     valueField.setVisible(true);
@@ -228,7 +228,7 @@ public class RedundancyPanel extends GSliderPanel implements Runnable
         }
       }
 
-      EditCommand cut = new EditCommand("Remove Redundancy",
+      EditCommand cut = new EditCommand(MessageManager.getString("action.remove_redundancy"),
               EditCommand.CUT, deleted, 0, width, ap.av.getAlignment());
 
       for (int i = 0; i < del.size(); i++)
index bf5ea93..02c6c16 100644 (file)
@@ -949,7 +949,7 @@ public class SeqPanel extends JPanel implements MouseListener,
       message.append("Edit group:");
       if (editCommand == null)
       {
-        editCommand = new EditCommand("Edit Group");
+        editCommand = new EditCommand(MessageManager.getString("action.edit_group"));
       }
     }
     else
@@ -962,7 +962,7 @@ public class SeqPanel extends JPanel implements MouseListener,
       }
       if (editCommand == null)
       {
-        editCommand = new EditCommand("Edit " + label);
+        editCommand = new EditCommand(MessageManager.formatMessage("label.edit_params", new String[]{label}));
       }
     }
 
index b2bf35f..35bc29a 100755 (executable)
@@ -78,7 +78,7 @@ public class SequenceFetcher extends JPanel implements Runnable
       if (guiWindow != null)
       {
         guiWindow.setProgressBar(
-                "Waiting for Sequence Database Fetchers to initialise",
+                MessageManager.getString("status.waiting_sequence_database_fetchers_init"),
                 Thread.currentThread().hashCode());
       }
       // initting happening on another thread - so wait around to see if it
@@ -97,7 +97,7 @@ public class SequenceFetcher extends JPanel implements Runnable
       if (guiWindow != null)
       {
         guiWindow.setProgressBar(
-                "Waiting for Sequence Database Fetchers to initialise",
+                       MessageManager.getString("status.waiting_sequence_database_fetchers_init"),
                 Thread.currentThread().hashCode());
       }
     }
@@ -115,7 +115,7 @@ public class SequenceFetcher extends JPanel implements Runnable
        */
       if (guiWindow != null)
       {
-        guiWindow.setProgressBar("Initialising Sequence Database Fetchers",
+        guiWindow.setProgressBar(MessageManager.getString("status.init_sequence_database_fetchers"),
                 Thread.currentThread().hashCode());
       }
       dasRegistry = jalview.bin.Cache.getDasSourceRegistry();
@@ -124,7 +124,7 @@ public class SequenceFetcher extends JPanel implements Runnable
       jalview.ws.SequenceFetcher sf = new jalview.ws.SequenceFetcher();
       if (guiWindow != null)
       {
-        guiWindow.setProgressBar("Initialising Sequence Database Fetchers",
+        guiWindow.setProgressBar(MessageManager.getString("status.init_sequence_database_fetchers"),
                 Thread.currentThread().hashCode());
       }
       lastDasSourceRegistry = (dasRegistry.getDasRegistryURL() + dasRegistry
@@ -161,8 +161,8 @@ public class SequenceFetcher extends JPanel implements Runnable
               JOptionPane
                       .showInternalMessageDialog(
                               Desktop.desktop,
-                              "Could not create the sequence fetcher client. Check error logs for details.",
-                              "Couldn't create SequenceFetcher",
+                              MessageManager.getString("warn.couldnt_create_sequence_fetcher_client"),
+                              MessageManager.getString("label.couldnt_create_sequence_fetcher"),
                               JOptionPane.ERROR_MESSAGE);
             }
           });
@@ -219,8 +219,7 @@ public class SequenceFetcher extends JPanel implements Runnable
 
   private String getFrameTitle()
   {
-    return ((alignFrame == null) ? "New " : "Additional ")
-            + "Sequence Fetcher";
+    return ((alignFrame == null) ? MessageManager.getString("label.new_sequence_fetcher") : MessageManager.getString("label.additional_sequence_fetcher"));
   }
 
   private void jbInit() throws Exception
@@ -494,8 +493,7 @@ public class SequenceFetcher extends JPanel implements Runnable
       try
       {
         // update status
-        guiWindow.setProgressBar("Fetching " + nqueries
-                + " sequence queries from " + proxy.getDbName(), Thread
+        guiWindow.setProgressBar(MessageManager.formatMessage("status.fetching_sequence_queries_from", new String[]{Integer.valueOf(nqueries).toString(),proxy.getDbName()}), Thread
                 .currentThread().hashCode());
         isAliSource = proxy.isA(DBRefSource.ALIGNMENTDB);
         if (proxy.getAccessionSeparator() == null)
@@ -693,11 +691,11 @@ public class SequenceFetcher extends JPanel implements Runnable
           presultTitle.add(titl);
         }
       }
-      guiWindow.setProgressBar("Finished querying", Thread.currentThread()
+      guiWindow.setProgressBar(MessageManager.getString("status.finshed_querying"), Thread.currentThread()
               .hashCode());
     }
-    guiWindow.setProgressBar((presult.size() > 0) ? "Parsing results."
-            : "Processing ..", Thread.currentThread().hashCode());
+    guiWindow.setProgressBar((presult.size() > 0) ? MessageManager.getString("status.parsing_results")
+            : MessageManager.getString("status.processing"), Thread.currentThread().hashCode());
     // process results
     while (presult.size() > 0)
     {
index 48f09f8..81b3bd3 100755 (executable)
@@ -136,8 +136,7 @@ public class SliderPanel extends GSliderPanel
       sp.cs = cs;
     }
 
-    conservationSlider.setTitle("Conservation Colour Increment  (" + source
-            + ")");
+    conservationSlider.setTitle(MessageManager.formatMessage("label.conservation_colour_increment", new String[]{source}));
 
     if (ap.av.getAlignment().getGroups() != null)
     {
@@ -213,7 +212,7 @@ public class SliderPanel extends GSliderPanel
       pid.cs = cs;
     }
 
-    PIDSlider.setTitle("Percentage Identity Threshold (" + source + ")");
+    PIDSlider.setTitle(MessageManager.formatMessage("label.percentage_identity_thereshold", new String[]{source}));
 
     if (ap.av.getAlignment().getGroups() != null)
     {
index dc705b2..6fe7660 100644 (file)
@@ -68,9 +68,7 @@ public class TextColourChooser
     JPanel panel = new JPanel();
     bigpanel.add(panel, BorderLayout.CENTER);
     bigpanel.add(
-            new JLabel(
-                    "<html><i>Select a dark and light text colour, then set the threshold to"
-                            + "<br>switch between colours, based on background colour</i></html>"),
+            new JLabel(MessageManager.getString("label.select_dark_light_set_thereshold")),
             BorderLayout.NORTH);
     panel.add(col1);
     panel.add(slider);
@@ -81,7 +79,7 @@ public class TextColourChooser
       public void mousePressed(MouseEvent e)
       {
         Color col = JColorChooser.showDialog(bigpanel,
-                "Select Colour for Text", col1.getBackground());
+                MessageManager.getString("label.select_colour_for_text"), col1.getBackground());
         if (col != null)
         {
           colour1Changed(col);
@@ -95,7 +93,7 @@ public class TextColourChooser
       public void mousePressed(MouseEvent e)
       {
         Color col = JColorChooser.showDialog(bigpanel,
-                "Select Colour for Text", col2.getBackground());
+                       MessageManager.getString("label.select_colour_for_text"), col2.getBackground());
         if (col != null)
         {
           colour2Changed(col);
@@ -113,7 +111,7 @@ public class TextColourChooser
     });
 
     int reply = JOptionPane.showInternalOptionDialog(ap, bigpanel,
-            "Adjust Foreground Text Colour Threshold",
+            MessageManager.getString("label.adjunst_foreground_text_colour_thereshold"),
             JOptionPane.OK_CANCEL_OPTION, JOptionPane.QUESTION_MESSAGE,
             null, null, null);
 
index e188177..c5650f5 100755 (executable)
@@ -757,7 +757,7 @@ public class TreeCanvas extends JPanel implements MouseListener, Runnable,
       if (SwingUtilities.isRightMouseButton(evt))
       {
         Color col = JColorChooser.showDialog(this,
-                "Select Sub-Tree Colour", highlightNode.color);
+                MessageManager.getString("label.select_subtree_colour"), highlightNode.color);
         if (col != null)
         {
           setColor(highlightNode, col);
index cf49608..ee0bfaf 100755 (executable)
@@ -399,7 +399,7 @@ public class TreePanel extends GTreePanel
     JalviewFileChooser chooser = new JalviewFileChooser(
             jalview.bin.Cache.getProperty("LAST_DIRECTORY"));
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save tree as newick file");
+    chooser.setDialogTitle(MessageManager.getString("label.save_tree_as_newick"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(null);
@@ -695,7 +695,7 @@ public class TreePanel extends GTreePanel
               { "eps" }, new String[]
               { "Encapsulated Postscript" }, "Encapsulated Postscript");
       chooser.setFileView(new jalview.io.JalviewFileView());
-      chooser.setDialogTitle("Create EPS file from tree");
+      chooser.setDialogTitle(MessageManager.getString("label.create_eps_from_tree"));
       chooser.setToolTipText(MessageManager.getString("action.save"));
 
       int value = chooser.showSaveDialog(this);
@@ -742,7 +742,7 @@ public class TreePanel extends GTreePanel
               { "Portable network graphics" }, "Portable network graphics");
 
       chooser.setFileView(new jalview.io.JalviewFileView());
-      chooser.setDialogTitle("Create PNG image from tree");
+      chooser.setDialogTitle(MessageManager.getString("label.create_png_from_tree"));
       chooser.setToolTipText(MessageManager.getString("action.save"));
 
       int value = chooser.showSaveDialog(this);
index 43c648e..7bf2e6c 100755 (executable)
@@ -778,7 +778,7 @@ public class UserDefinedColours extends GUserDefinedColours implements
             { "Jalview User Colours" }, "Jalview User Colours");
 
     chooser.setFileView(new jalview.io.JalviewFileView());
-    chooser.setDialogTitle("Save colour scheme");
+    chooser.setDialogTitle(MessageManager.getString("label.save_colour_scheme"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(this);
index b789040..77a7693 100644 (file)
@@ -31,6 +31,7 @@ import jalview.structure.SelectionSource;
 import jalview.structure.StructureSelectionManager;
 import jalview.structure.VamsasListener;
 import jalview.structure.VamsasSource;
+import jalview.util.MessageManager;
 
 import java.beans.PropertyChangeEvent;
 import java.beans.PropertyChangeListener;
@@ -155,8 +156,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
       {
         if (sess != null)
         {
-          throw new Error(
-                  "Implementation Error - cannot import existing vamsas document into an existing session, Yet!");
+          throw new Error(MessageManager.getString("error.implementation_error_cannot_import_vamsas_doc"));
         }
         try
         {
@@ -176,8 +176,8 @@ public class VamsasApplication implements SelectionSource, VamsasSource
                   .showInternalMessageDialog(
                           Desktop.desktop,
 
-                          "VAMSAS Document could not be opened as a new session - please choose another",
-                          "VAMSAS Document Import Failed",
+                          MessageManager.getString("label.vamsas_doc_couldnt_be_opened_as_new_session"),
+                          MessageManager.getString("label.vamsas_document_import_failed"),
                           JOptionPane.ERROR_MESSAGE);
 
         }
@@ -263,8 +263,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
   {
     if (!inSession())
     {
-      throw new Error(
-              "Impementation error! Vamsas Operations when client not initialised and connected.");
+      throw new Error(MessageManager.getString("error.implementation_error_vamsas_operation_not_init"));
     }
     addDocumentUpdateHandler();
     addStoreDocumentHandler();
@@ -348,7 +347,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
   public void end_session(boolean promptUser)
   {
     if (!inSession())
-      throw new Error("Jalview not connected to Vamsas session.");
+      throw new Error(MessageManager.getString("error.jalview_no_connected_vamsas_session"));
     Cache.log.info("Jalview disconnecting from the Vamsas Session.");
     try
     {
@@ -716,8 +715,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
         return;
       }
 
-      throw new Error(
-              "IMPLEMENTATION ERROR: Cannot recover vamsas object mappings - no backup was made.");
+      throw new Error(MessageManager.getString("error.implementation_error_cannot_recover_vamsas_object_mappings"));
     }
     jv2vobj.clear();
     Iterator el = _backup_jv2vobj.entrySet().iterator();
index 2afec55..8dcf72a 100644 (file)
@@ -356,8 +356,7 @@ public class WebserviceInfo extends GWebserviceInfo implements
   {
     if (jobpane < 0 || jobpane >= jobPanes.size())
     {
-      throw new Error("setStatus called for non-existent job pane."
-              + jobpane);
+      throw new Error(MessageManager.formatMessage("error.setstatus_called_non_existent_job_pane", new String[]{Integer.valueOf(jobpane).toString()}));
     }
     switch (status)
     {
@@ -651,8 +650,8 @@ public class WebserviceInfo extends GWebserviceInfo implements
       // anyhow - it has to stop threads and clean up
       // JBPNote : TODO: Instead of a warning, we should have an optional 'Are
       // you sure?' prompt
-      warnUser("This job cannot be cancelled.\nJust close the window.",
-              "Cancel job");
+      warnUser(MessageManager.getString("warn.job_cannot_be_cancelled_close_window"),
+              MessageManager.getString("action.cancel_job"));
     }
     else
     {
@@ -912,8 +911,7 @@ public class WebserviceInfo extends GWebserviceInfo implements
   {
     if (progressBarHandlers == null || !progressBars.contains(new Long(id)))
     {
-      throw new Error(
-              "call setProgressBar before registering the progress bar's handler.");
+      throw new Error(MessageManager.getString("error.call_setprogressbar_before_registering_handler"));
     }
     progressBarHandlers.put(new Long(id), handler);
     final JPanel progressPanel = (JPanel) progressBars.get(new Long(id));
@@ -929,10 +927,7 @@ public class WebserviceInfo extends GWebserviceInfo implements
         public void actionPerformed(ActionEvent e)
         {
           handler.cancelActivity(id);
-          us.setProgressBar(
-                  "Cancelled "
-                          + ((JLabel) progressPanel.getComponent(0))
-                                  .getText(), id);
+          us.setProgressBar(MessageManager.formatMessage("label.cancelled_params", new String[]{((JLabel) progressPanel.getComponent(0)).getText()}), id);
         }
       });
       progressPanel.add(cancel, BorderLayout.EAST);
index 0c9937d..23645df 100644 (file)
@@ -218,7 +218,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
 
     frame = new JDialog(Desktop.instance, true);
 
-    frame.setTitle("Edit parameters for " + service.getActionText());
+    frame.setTitle(MessageManager.formatMessage("label.edit_params_for", new String[]{service.getActionText()}));
     Rectangle deskr = Desktop.instance.getBounds();
     Dimension pref = this.getPreferredSize();
     frame.setBounds(new Rectangle(
@@ -1091,8 +1091,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
             }
             WsJobParameters pgui = new WsJobParameters(lastserv,
                     new JabaPreset(lastserv, pr));
-            JFrame jf = new JFrame("Parameters for "
-                    + lastserv.getActionText());
+            JFrame jf = new JFrame(MessageManager.formatMessage("label.ws_parameters_for", new String[]{lastserv.getActionText()}));
             JPanel cont = new JPanel(new BorderLayout());
             pgui.validate();
             cont.setPreferredSize(pgui.getPreferredSize());
@@ -1417,8 +1416,8 @@ public class WsJobParameters extends JPanel implements ItemListener,
             public void run()
             {
               JOptionPane.showMessageDialog(ourframe,
-                      "Invalid name - preset already exists.",
-                      "Invalid name", JOptionPane.WARNING_MESSAGE);
+                      MessageManager.getString("label.invalid_name_preset_exists"),
+                      MessageManager.getString("label.invalid_name"), JOptionPane.WARNING_MESSAGE);
             }
           });
 
index dec4745..3322d6a 100644 (file)
@@ -178,8 +178,7 @@ public class WsParamSetManager implements ParamManager
     }
     if (parser == null)
     {
-      throw new Error(
-              "Implementation error: Can't find a marshaller for the parameter set");
+      throw new Error(MessageManager.getString("error.implementation_error_cannot_find_marshaller_for_param_set"));
     }
     if (filename == null)
     {
@@ -189,7 +188,7 @@ public class WsParamSetManager implements ParamManager
               { "Web Service Parameter File" },
               "Web Service Parameter File");
       chooser.setFileView(new jalview.io.JalviewFileView());
-      chooser.setDialogTitle("Choose a filename for this parameter file");
+      chooser.setDialogTitle(MessageManager.getString("label.choose_filename_for_param_file"));
       chooser.setToolTipText(MessageManager.getString("action.save"));
       int value = chooser.showSaveDialog(Desktop.instance);
       if (value == JalviewFileChooser.APPROVE_OPTION)
index a85ebbf..876d157 100644 (file)
@@ -125,7 +125,7 @@ public class WsPreferences extends GWsPreferences
     }
 
     wsList.setModel(new WsUrlTableModel(tdat));
-    wsList.getColumn("Status").setMinWidth(10);
+    wsList.getColumn(MessageManager.getString("label.status")).setMinWidth(10);
   }
 
   private class JabaWSStatusRenderer extends JPanel implements
@@ -184,6 +184,8 @@ public class WsPreferences extends GWsPreferences
   {
 
     private Object[][] data;
+    private String[] columnNames = new String[]
+    { MessageManager.getString("label.service_url"), MessageManager.getString("label.status") };
 
     public WsUrlTableModel(Object[][] tdat)
     {
@@ -199,11 +201,7 @@ public class WsPreferences extends GWsPreferences
     @Override
     public String getColumnName(int column)
     {
-      if (column == 1)
-      {
-        return "Status";
-      }
-      return "Service URL";
+        return columnNames[column];
     }
 
     @Override
@@ -276,7 +274,7 @@ public class WsPreferences extends GWsPreferences
     int sel = wsList.getSelectedRow();
     if (sel > -1)
     {
-      String url = editUrl(wsUrls.elementAt(sel), "Edit JABAWS URL");
+      String url = editUrl(wsUrls.elementAt(sel), MessageManager.getString("label.edit_jabaws_url"));
       if (url != null)
       {
         int present = wsUrls.indexOf(url);
@@ -302,7 +300,7 @@ public class WsPreferences extends GWsPreferences
   protected void newSbrsUrl_actionPerformed(ActionEvent e)
   {
     RestServiceEditorPane rse = new RestServiceEditorPane();
-    rse.showDialog("Add a new Simple Bioinformatics Rest Service");
+    rse.showDialog(MessageManager.getString("label.add_new_sbrs_service"));
     String rservice = rse.getEditedRestService();
     if (rservice != null && !rsbsUrls.contains(rservice))
     {
@@ -320,7 +318,7 @@ public class WsPreferences extends GWsPreferences
     {
       RestServiceEditorPane rse = new RestServiceEditorPane(
               new RestServiceDescription(rsbsUrls.elementAt(sel)));
-      rse.showDialog("Edit Simple Bioinformatics Rest Service entry");
+      rse.showDialog(MessageManager.getString("label.edit_sbrs_entry"));
       String rservice = rse.getEditedRestService();
       if (rservice != null)
       {
@@ -484,8 +482,8 @@ public class WsPreferences extends GWsPreferences
       int validate = JOptionPane
               .showInternalConfirmDialog(
                       Desktop.desktop,
-                      "Validate JabaWS Server ?\n(Look in console output for results)",
-                      "Test Server?", JOptionPane.YES_NO_OPTION);
+                      MessageManager.getString("info.validate_jabaws_server"),
+                      MessageManager.getString("label.test_server"), JOptionPane.YES_NO_OPTION);
       if (validate == JOptionPane.OK_OPTION)
       {
         if (jalview.ws.jws2.Jws2Discoverer.testServiceUrl(foo))
@@ -497,7 +495,7 @@ public class WsPreferences extends GWsPreferences
           JOptionPane
                   .showInternalMessageDialog(
                           Desktop.desktop,
-                          "Service did not pass validation.\nCheck the Jalview Console for more details.");
+                          MessageManager.getString("warn.server_didnt_pass_validation"));
         }
       }
       else
@@ -518,7 +516,7 @@ public class WsPreferences extends GWsPreferences
   @Override
   protected void newWsUrl_actionPerformed(ActionEvent e)
   {
-    String url = editUrl(null, "Add new JABAWS URL");
+    String url = editUrl(null, MessageManager.getString("label.add_jabaws_url"));
     if (url != null)
     {
       if (!wsUrls.contains(url))
@@ -603,7 +601,7 @@ public class WsPreferences extends GWsPreferences
         public void run()
         {
           long ct = System.currentTimeMillis();
-          Desktop.instance.setProgressBar("Refreshing Web Service Menus",
+          Desktop.instance.setProgressBar(MessageManager.getString("status.refreshing_web_service_menus"),
                   ct);
           if (lastrefresh != update)
           {
index c3c86d6..f73e250 100755 (executable)
@@ -24,6 +24,7 @@ import jalview.datamodel.Alignment;
 import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.Sequence;
 import jalview.datamodel.SequenceI;
+import jalview.util.MessageManager;
 
 import java.io.IOException;
 import java.util.Enumeration;
@@ -196,8 +197,7 @@ public abstract class AlignFile extends FileParse
   {
     if (key == null)
     {
-      throw new Error(
-              "Implementation error: Cannot have null alignment property key.");
+      throw new Error(MessageManager.getString("error.implementation_error_cannot_have_null_alignment"));
     }
     if (value == null)
     {
index d43e7c1..ed49d5e 100755 (executable)
@@ -25,6 +25,7 @@ import jalview.datamodel.Alignment;
 import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.AlignmentI;
 import jalview.datamodel.AlignmentView;
+import jalview.util.MessageManager;
 
 import java.io.File;
 import java.io.InputStream;
@@ -516,8 +517,7 @@ public class AppletFormatAdapter
 
       else
       {
-        throw new Exception(
-                "Implementation error: Unknown file format string");
+        throw new Exception(MessageManager.getString("error.implementation_error_unknown_file_format_string"));
       }
       afile.setNewlineString(newline);
       afile.addJVSuffix(jvsuffix);
index 4ec464a..0f94efa 100755 (executable)
@@ -417,11 +417,8 @@ public class FileLoader implements Runnable
             javax.swing.JOptionPane
                     .showInternalMessageDialog(
                             Desktop.desktop,
-                            "Out of memory loading file "
-                                    + file
-                                    + "!!"
-                                    + "\nSee help files for increasing Java Virtual Machine memory.",
-                            "Out of memory",
+                            MessageManager.formatMessage("warn.out_of_memory_loading_file", new String[]{file}),
+                            MessageManager.getString("label.out_of_memory"),
                             javax.swing.JOptionPane.WARNING_MESSAGE);
           }
         });
index e8e9f2e..8e9a49c 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package jalview.io;
 
+import jalview.util.MessageManager;
+
 import java.io.*;
 import java.net.*;
 import java.util.zip.GZIPInputStream;
@@ -94,8 +96,7 @@ public class FileParse
   {
     if (from == null)
     {
-      throw new Error(
-              "Implementation error. Null FileParse in copy constructor");
+      throw new Error(MessageManager.getString("error.implementation_error_null_fileparse"));
     }
     if (from == this)
       return;
@@ -208,7 +209,7 @@ public class FileParse
     {
       if (e != null)
       {
-        throw new IOException("Failed to resolve GZIP stream", e);
+        throw new IOException(MessageManager.getString("exception.failed_to_resolve_gzip_stream"), e);
       }
       throw q;
     }
@@ -263,14 +264,12 @@ public class FileParse
         {
           if (checkFileSource(suffixLess))
           {
-            throw new IOException("Problem opening " + inFile
-                    + " (also tried " + suffixLess + ") : " + errormessage);
+            throw new IOException(MessageManager.formatMessage("exception.problem_opening_file_also_tried", new String[]{inFile.getName(),suffixLess,errormessage}));
           }
         }
         else
         {
-          throw new IOException("Problem opening " + inFile + " : "
-                  + errormessage);
+          throw new IOException(MessageManager.formatMessage("exception.problem_opening_file", new String[]{inFile.getName(),errormessage}));
         }
       }
     }
@@ -345,8 +344,7 @@ public class FileParse
     if (dataIn == null || error)
     {
       // pass up the reason why we have no source to read from
-      throw new IOException("Failed to read data from source:\n"
-              + errormessage);
+      throw new IOException(MessageManager.formatMessage("exception.failed_to_read_data_from_source", new String[]{errormessage}));
     }
     error = false;
     dataIn.mark(READAHEAD_LIMIT);
@@ -366,7 +364,7 @@ public class FileParse
     }
     else
     {
-      throw new IOException("Unitialised Source Stream");
+      throw new IOException(MessageManager.getString("exception.no_init_source_stream"));
     }
   }
 
@@ -374,7 +372,7 @@ public class FileParse
   {
     if (!error)
       return dataIn.readLine();
-    throw new IOException("Invalid Source Stream:" + errormessage);
+    throw new IOException(MessageManager.formatMessage("exception.invalid_source_stream", new String[]{errormessage}));
   }
 
   public boolean isValid()
@@ -406,8 +404,7 @@ public class FileParse
     }
     else
     {
-      throw new IOException(
-              "Implementation Error: Reset called for invalid source.");
+      throw new IOException(MessageManager.getString("error.implementation_error_reset_called_for_invalid_source"));
     }
   }
 
index ac7f5b3..50b07e4 100755 (executable)
@@ -53,7 +53,7 @@ public class HTMLOutput
             { "HTML files" }, "HTML files");
 
     chooser.setFileView(new JalviewFileView());
-    chooser.setDialogTitle("Save as HTML");
+    chooser.setDialogTitle(MessageManager.getString("label.save_as_html"));
     chooser.setToolTipText(MessageManager.getString("action.save"));
 
     int value = chooser.showSaveDialog(null);
index 0b3cd13..ca74f2c 100755 (executable)
@@ -29,6 +29,7 @@ import java.io.*;
 import java.util.*;
 
 import jalview.datamodel.*;
+import jalview.util.MessageManager;
 
 /**
  * Parser for the JPred/JNet concise format. This is a series of CSV lines, each
@@ -293,9 +294,7 @@ public class JPredFile extends AlignFile
 
       if (maxLength != seq_entries.elementAt(i).toString().length())
       {
-        throw new IOException("JPredConcise: Entry ("
-                + ids.elementAt(i).toString()
-                + ") has an unexpected number of columns");
+        throw new IOException(MessageManager.formatMessage("exception.jpredconcide_entry_has_unexpected_number_of_columns", new String[]{ids.elementAt(i).toString()}));
       }
 
       if ((newSeq.getName().startsWith("QUERY") || newSeq.getName()
@@ -319,9 +318,7 @@ public class JPredFile extends AlignFile
       } catch (Exception e)
       {
         tal = null;
-        IOException ex = new IOException(
-                "Couldn't parse concise annotation for prediction profile.\n"
-                        + e);
+        IOException ex = new IOException(MessageManager.formatMessage("exception.couldnt_parse_concise_annotation_for_prediction", new String[]{e.getMessage()}));
         e.printStackTrace(); // java 1.1 does not have :
                              // ex.setStackTrace(e.getStackTrace());
         throw ex;
index 684fa9e..df8decf 100755 (executable)
@@ -222,7 +222,7 @@ public class JalviewFileChooser extends JFileChooser
             && getSelectedFile().exists())
     {
       int confirm = JOptionPane.showConfirmDialog(parent,
-              "Overwrite existing file?", "File exists",
+              MessageManager.getString("label.overwrite_existing_file"), MessageManager.getString("label.file_already_exists"),
               JOptionPane.YES_NO_OPTION);
 
       if (confirm != JOptionPane.YES_OPTION)
@@ -289,7 +289,7 @@ public class JalviewFileChooser extends JFileChooser
         }
       });
 
-      this.setBorder(new javax.swing.border.TitledBorder("Recently Opened"));
+      this.setBorder(new javax.swing.border.TitledBorder(MessageManager.getString("label.recently_opened")));
 
       final JScrollPane scroller = new JScrollPane(list);
       scroller.setPreferredSize(new Dimension(130, 200));
index dabd8ca..5c95a3f 100755 (executable)
@@ -21,6 +21,7 @@
 package jalview.io;
 
 import jalview.datamodel.*;
+import jalview.util.MessageManager;
 
 public class JnetAnnotationMaker
 {
@@ -60,13 +61,12 @@ public class JnetAnnotationMaker
     if ((delMap != null && delMap.length > width)
             || (delMap == null && gapmap.length != width))
     {
-      throw (new Exception("Number of residues in "
-              + (delMap == null ? "" : " mapped ")
-              + "supposed query sequence ('"
-              + al.getSequenceAt(firstSeq).getName() + "'\n"
-              + al.getSequenceAt(firstSeq).getSequenceAsString()
-              + ")\ndiffer from number of prediction sites in prediction ("
-              + width + ")"));
+      throw (new Exception(MessageManager.formatMessage("exception.number_of_residues_in_query_sequence_differ_from_prediction", new String[]{
+                 (delMap == null ? "" : MessageManager.getString("label.mapped")),
+                 al.getSequenceAt(firstSeq).getName(),
+                 al.getSequenceAt(firstSeq).getSequenceAsString(),
+                 Integer.valueOf(width).toString()
+      })));
     }
 
     AlignmentAnnotation annot;
index 9c91c13..f2a29ea 100755 (executable)
@@ -30,6 +30,7 @@ import java.io.*;
 import java.util.StringTokenizer;
 
 import jalview.datamodel.*;
+import jalview.util.MessageManager;
 
 /**
  * Parse a new hanpshire style tree Caveats: NHX files are NOT supported and the
@@ -611,11 +612,11 @@ public class NewickFile extends FileParse
 
     if (Error != null)
     {
-      throw (new IOException("NewickFile: " + Error + "\n"));
+      throw (new IOException(MessageManager.formatMessage("exception.newfile", new String[]{Error.toString()})));
     }
     if (root == null)
     {
-      throw (new IOException("NewickFile: No Tree read in\n"));
+        throw (new IOException(MessageManager.formatMessage("exception.newfile", new String[]{MessageManager.getString("label.no_tree_read_in")})));
     }
     // THe next line is failing for topali trees - not sure why yet. if
     // (root.right()!=null && root.isDummy())
index 361b47f..7d4baa2 100755 (executable)
@@ -100,7 +100,7 @@ public class PfamFile extends AlignFile
 
     if (noSeqs < 1)
     {
-      throw new IOException("No sequences found (PFAM input)");
+      throw new IOException(MessageManager.getString("exception.pfam_no_sequences_found"));
     }
 
     for (i = 0; i < headers.size(); i++)
index 2b9a7b0..d366edc 100644 (file)
@@ -31,6 +31,7 @@ import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.Annotation;
 import jalview.datamodel.Sequence;
 import jalview.datamodel.SequenceI;
+import jalview.util.MessageManager;
 
 import fr.orsay.lri.varna.exceptions.ExceptionFileFormatOrSyntax;
 import fr.orsay.lri.varna.exceptions.ExceptionLoadingFailed;
@@ -97,24 +98,21 @@ public class RnamlFile extends AlignFile
       _parse();
     } catch (ExceptionPermissionDenied pdx)
     {
-      errormessage = "Couldn't access datasource (" + pdx.getMessage()
-              + ")";
+      errormessage = MessageManager.formatMessage("exception.rnaml_couldnt_access_datasource", new String[]{pdx.getMessage()});
       throw new IOException(pdx);
     } catch (ExceptionLoadingFailed lf)
     {
-      errormessage = "Couldn't process data as RNAML file ("
-              + lf.getMessage() + ")";
+      errormessage = MessageManager.formatMessage("exception.ranml_couldnt_process_data", new String[]{lf.getMessage()});
       throw new IOException(lf);
     } catch (ExceptionFileFormatOrSyntax iff)
     {
-      errormessage = "Invalid RNAML file (" + iff.getMessage() + ")";
+        errormessage = MessageManager.formatMessage("exception.ranml_invalid_file", new String[]{iff.getMessage()});
       throw new IOException(iff);
     } catch (Exception x)
     {
       error = true;
-      errormessage = "Problem parsing data as RNAML (" + x.getMessage()
-              + ")";
-      throw new IOException("Couldn't parse the datasource as RNAML", x);
+      errormessage = MessageManager.formatMessage("exception.ranml_problem_parsing_data", new String[]{x.getMessage()});
+      throw new IOException(errormessage , x);
     }
   }
 
index 9d21a40..0a18be0 100644 (file)
@@ -33,6 +33,7 @@ import jalview.datamodel.Sequence;
 import jalview.datamodel.SequenceFeature;
 import jalview.datamodel.SequenceI;
 import jalview.util.Format;
+import jalview.util.MessageManager;
 
 import java.io.BufferedReader;
 import java.io.FileReader;
@@ -197,8 +198,7 @@ public class StockholmFile extends AlignFile
     r = new Regex("# STOCKHOLM ([\\d\\.]+)");
     if (!r.search(nextLine()))
     {
-      throw new IOException(
-              "This file is not in valid STOCKHOLM format: First line does not contain '# STOCKHOLM'");
+      throw new IOException(MessageManager.getString("exception.stockholm_invalid_format"));
     }
     else
     {
@@ -416,7 +416,7 @@ public class StockholmFile extends AlignFile
         if (!x.search(line))
         {
           // logger.error("Could not parse sequence line: " + line);
-          throw new IOException("Could not parse sequence line: " + line);
+          throw new IOException(MessageManager.formatMessage("exception.couldnt_parse_sequence_line", new String[]{line}));
         }
         String ns = (String) seqs.get(x.stringMatched(1));
         if (ns == null)
@@ -528,7 +528,7 @@ public class StockholmFile extends AlignFile
           }
           else
           {
-            throw new IOException("Error parsing " + line);
+            throw new IOException(MessageManager.formatMessage("exception.error_parsing_line", new String[]{line}));
           }
         }
         else if (annType.equals("GC"))
@@ -653,8 +653,7 @@ public class StockholmFile extends AlignFile
         }
         else
         {
-          throw new IOException("Unknown annotation detected: " + annType
-                  + " " + annContent);
+          throw new IOException(MessageManager.formatMessage("exception.unknown_annotation_detected", new String[]{annType,annContent}));
         }
       }
     }
index 6472dd3..6293a1b 100644 (file)
@@ -33,6 +33,8 @@ import jalview.io.vamsas.Datasetsequence;
 import jalview.io.vamsas.DatastoreItem;
 import jalview.io.vamsas.DatastoreRegistry;
 import jalview.io.vamsas.Rangetype;
+import jalview.util.MessageManager;
+
 import java.io.IOException;
 import java.util.Enumeration;
 import java.util.HashMap;
@@ -222,8 +224,7 @@ public class VamsasAppDatastore
     {
       Cache.log.debug(
               "Warning? Overwriting existing vamsas id binding for "
-                      + vobj.getVorbaId(), new Exception(
-                      "Overwriting vamsas id binding."));
+                      + vobj.getVorbaId(), new Exception(MessageManager.getString("exception.overwriting_vamsas_id_binding")));
     }
     else if (jv2vobj.containsKey(jvobj)
             && !((VorbaId) jv2vobj.get(jvobj)).equals(vobj.getVorbaId()))
@@ -310,8 +311,7 @@ public class VamsasAppDatastore
                 if (vbound.getV_parent() != null
                         && dataset != vbound.getV_parent())
                 {
-                  throw new Error(
-                          "IMPLEMENTATION ERROR: Cannot map an alignment of sequences from different datasets into a single alignment in the vamsas document.");
+                  throw new Error(MessageManager.getString("error.implementation_error_cannot_map_alignment_sequences"));
                   // This occurs because the dataset for the alignment we are
                   // trying to
                 }
@@ -1473,9 +1473,7 @@ public class VamsasAppDatastore
     {
       // NOTE: this happens if user deletes object in one session then updates
       // from another client
-      throw new Error(
-              "IMPLEMENTATION ERROR: old jalview object is not bound ! ("
-                      + oldjvobject + ")");
+      throw new Error(MessageManager.formatMessage("error.implementation_error_old_jalview_object_not_bound", new String[]{oldjvobject.toString()}));
     }
     if (newjvobject != null)
     {
@@ -2417,8 +2415,7 @@ public class VamsasAppDatastore
       int[] se = null;
       if (dseta.getSegCount() > 0 && dseta.getPosCount() > 0)
       {
-        throw new Error(
-                "Invalid vamsas RangeType - cannot resolve both lists of Pos and Seg from choice!");
+        throw new Error(MessageManager.getString("error.invalid_vamsas_rangetype_cannot_resolve_lists"));
       }
       if (dseta.getSegCount() > 0)
       {
@@ -2476,8 +2473,7 @@ public class VamsasAppDatastore
       int[] se = null;
       if (dseta.getSegCount() > 0 && dseta.getPosCount() > 0)
       {
-        throw new Error(
-                "Invalid vamsas RangeType - cannot resolve both lists of Pos and Seg from choice!");
+          throw new Error(MessageManager.getString("error.invalid_vamsas_rangetype_cannot_resolve_lists"));
       }
       if (dseta.getSegCount() > 0)
       {
@@ -2733,8 +2729,7 @@ public class VamsasAppDatastore
       }
     } catch (Exception e)
     {
-      throw new Exception("Couldn't store sequence mappings for " + title,
-              e);
+      throw new Exception(MessageManager.formatMessage("exception.couldnt_store_sequence_mappings", new String[]{title}),e);
     }
   }
 
index cc5fbed..4f0d802 100755 (executable)
@@ -208,8 +208,7 @@ public class WSWUBlastClient
           imageIndex++;
           imageIndex %= 9;
           output.setFrameIcon(imageIcon[imageIndex]);
-          output.setTitle("BLASTing for unidentified sequences - "
-                  + jobsRunning + " jobs running.");
+          output.setTitle(MessageManager.formatMessage("label.blasting_for_unidentified_sequence_jobs_running", new String[]{Integer.valueOf(jobsRunning).toString()}));
         } catch (Exception ex)
         {
         }
index 74c5bd1..2a070e8 100644 (file)
@@ -22,6 +22,7 @@ package jalview.io.vamsas;
 
 import jalview.bin.Cache;
 import jalview.io.VamsasAppDatastore;
+import jalview.util.MessageManager;
 
 import java.util.Enumeration;
 import java.util.Hashtable;
@@ -131,16 +132,14 @@ public abstract class DatastoreItem
     {
       Cache.log.debug(
               "Warning? Overwriting existing vamsas id binding for "
-                      + vobj.getVorbaId(), new Exception(
-                      "Overwriting vamsas id binding."));
+                      + vobj.getVorbaId(), new Exception(MessageManager.getString("exception.overwriting_vamsas_id_binding")));
     }
     else if (jv2vobj.containsKey(jvobj)
             && !((VorbaId) jv2vobj.get(jvobj)).equals(vobj.getVorbaId()))
     {
       Cache.log.debug(
               "Warning? Overwriting existing jalview object binding for "
-                      + jvobj, new Exception(
-                      "Overwriting jalview object binding."));
+                      + jvobj, new Exception(MessageManager.getString("exception.overwriting_jalview_id_binding")));
     }
     /*
      * Cache.log.error("Attempt to make conflicting object binding! "+vobj+" id "
@@ -190,9 +189,7 @@ public abstract class DatastoreItem
     Object vobject = jv2vobj.remove(oldjvobject);
     if (vobject == null)
     {
-      throw new Error(
-              "IMPLEMENTATION ERROR: old jalview object is not bound ! ("
-                      + oldjvobject + ")");
+      throw new Error(MessageManager.formatMessage("error.implementation_error_old_jalview_object_not_bound", new String[]{oldjvobject.toString()}));
     }
     if (newjvobject != null)
     {
@@ -231,9 +228,8 @@ public abstract class DatastoreItem
     tojalview = true;
     if (jvobj != null && !(boundType.isAssignableFrom(jvobj.getClass())))
     {
-      throw new Error("Implementation Error: Vamsas Document Class "
-              + vobj.getClass() + " should bind to a " + boundType
-              + " (found a " + jvobj.getClass() + ")");
+      throw new Error(MessageManager.formatMessage("error.implementation_error_vamsas_doc_class_should_bind_to_type"
+                       , new String[]{vobj.getClass().toString(),boundType.toString(),jvobj.getClass().toString()}));
     }
     dsReg.registerDsObj(this);
   }
@@ -259,9 +255,8 @@ public abstract class DatastoreItem
     vobj = getjv2vObj(jvobj);
     if (vobj != null && !(boundToType.isAssignableFrom(vobj.getClass())))
     {
-      throw new Error("Implementation Error: Jalview Class "
-              + jvobj2.getClass() + " should bind to a " + boundToType
-              + " (found a " + vobj.getClass() + ")");
+        throw new Error(MessageManager.formatMessage("error.implementation_error_vamsas_doc_class_should_bind_to_type"
+                       , new String[]{jvobj2.getClass().toString(),boundToType.toString(),vobj.getClass().toString()}));
     }
     dsReg.registerDsObj(this);
   }
index a2b5ff4..3cc977f 100644 (file)
@@ -29,6 +29,7 @@ import uk.ac.vamsas.objects.core.Mapped;
 import uk.ac.vamsas.objects.core.RangeType;
 import uk.ac.vamsas.objects.core.Seg;
 import jalview.io.VamsasAppDatastore;
+import jalview.util.MessageManager;
 
 /**
  * Enhances DatastoreItem objects with additional functions to do with RangeType
@@ -75,8 +76,7 @@ public abstract class Rangetype extends DatastoreItem
       int[] se = null;
       if (dseta.getSegCount() > 0 && dseta.getPosCount() > 0)
       {
-        throw new Error(
-                "Invalid vamsas RangeType - cannot resolve both lists of Pos and Seg from choice!");
+        throw new Error(MessageManager.getString("error.invalid_vamsas_rangetype_cannot_resolve_lists"));
       }
       if (dseta.getSegCount() > 0)
       {
@@ -134,8 +134,7 @@ public abstract class Rangetype extends DatastoreItem
       int[] se = null;
       if (dseta.getSegCount() > 0 && dseta.getPosCount() > 0)
       {
-        throw new Error(
-                "Invalid vamsas RangeType - cannot resolve both lists of Pos and Seg from choice!");
+        throw new Error(MessageManager.getString("error.invalid_vamsas_rangetype_cannot_resolve_lists"));
       }
       if (dseta.getSegCount() > 0)
       {
@@ -182,8 +181,7 @@ public abstract class Rangetype extends DatastoreItem
       int[] se = null;
       if (range.getSegCount() > 0 && range.getPosCount() > 0)
       {
-        throw new Error(
-                "Invalid vamsas RangeType - cannot resolve both lists of Pos and Seg from choice!");
+        throw new Error(MessageManager.getString("error.invalid_vamsas_rangetype_cannot_resolve_lists"));
       }
       if (range.getSegCount() > 0)
       {
@@ -299,8 +297,7 @@ public abstract class Rangetype extends DatastoreItem
   {
     if (ml == null)
     {
-      throw new Error(
-              "Implementation error. MapList is null for initMapType.");
+      throw new Error(MessageManager.getString("error.implementation_error_maplist_is_null"));
     }
     maprange.setLocal(new Local());
     maprange.setMapped(new Mapped());
index d3154c7..e122f21 100755 (executable)
@@ -799,7 +799,7 @@ public class GAlignFrame extends JInternalFrame
       }
     });
     removeRedundancyMenuItem.setText(MessageManager
-            .getString("action.remove_redundancy"));
+            .getString("action.remove_redundancy").concat("..."));
     removeRedundancyMenuItem.setAccelerator(javax.swing.KeyStroke
             .getKeyStroke(java.awt.event.KeyEvent.VK_D, Toolkit
                     .getDefaultToolkit().getMenuShortcutKeyMask(), false));
index 86fe535..bf01a01 100755 (executable)
@@ -677,10 +677,7 @@ public class GPreferences extends JPanel
     autoIdWidth.setText(MessageManager
             .getString("label.automatically_set_id_width"));
     autoIdWidth
-            .setToolTipText("<html>"
-                    + JvSwingUtils
-                            .wrapTooltip("Adjusts the width of the generated EPS or PNG file to ensure even the longest sequence ID or annotation label is displayed")
-                    + "</html>");
+            .setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager.getString("label.adjusts_width_generated_eps_png")));
     autoIdWidth.setBounds(new Rectangle(228, 96, 188, 23));
     autoIdWidth.addActionListener(new ActionListener()
     {
@@ -695,15 +692,9 @@ public class GPreferences extends JPanel
     userIdWidthlabel.setText(MessageManager
             .getString("label.figure_id_column_width"));
     userIdWidth
-            .setToolTipText("<html>"
-                    + JvSwingUtils
-                            .wrapTooltip("Manually specify the width of the left hand column where sequence IDs and annotation labels will be rendered in exported alignment figures. This setting will be ignored if 'Automatically set ID width' is set")
-                    + "</html>");
+            .setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager.getString("label.manually_specify_width_left_column")));
     userIdWidthlabel
-            .setToolTipText("<html>"
-                    + JvSwingUtils
-                            .wrapTooltip("Manually specify the width of the left hand column where sequence IDs and annotation labels will be rendered in exported alignment figures. This setting will be ignored if 'Automatically set ID width' is set")
-                    + "</html>");
+            .setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager.getString("label.manually_specify_width_left_column")));
     userIdWidthlabel.setBounds(new Rectangle(236, 120, 168, 23));
     userIdWidth.setFont(JvSwingUtils.getTextAreaFont());
     userIdWidth.setText("");
index 259824a..e14e96b 100644 (file)
@@ -147,10 +147,8 @@ public class GRestServiceEditorPane extends JPanel
     // cpanel.setLayout(new FlowLayout());
     hSeparable = new JCheckBox(MessageManager.getString("label.per_seq"));
     hSeparable
-            .setToolTipText("<html>"
-                    + JvSwingUtils
-                            .wrapTooltip("When checked, a job is created for every sequence in the current selection.")
-                    + "<html>");
+            .setToolTipText(JvSwingUtils
+                            .wrapTooltip(false, MessageManager.getString("label.job_created_when_checked")));
     hSeparable.addActionListener(new ActionListener()
     {
 
@@ -164,13 +162,7 @@ public class GRestServiceEditorPane extends JPanel
     vSeparable = new JCheckBox(
             MessageManager.getString("label.result_vertically_separable"));
     vSeparable
-            .setToolTipText("<html>"
-                    + JvSwingUtils
-                            .wrapTooltip("When checked, a single job is created for the visible region and results"
-                                    + " mapped back onto their location in the alignment. Otherwise, a job would be"
-                                    + " created for every contiguous region visible in the alignment or current"
-                                    + " selection (e.g. a multiple alignment).")
-                    + "</html>");
+            .setToolTipText(JvSwingUtils.wrapTooltip(false, MessageManager.getString("label.when_checked_job_visible_region_and_results")));
     vSeparable.addActionListener(new ActionListener()
     {
 
@@ -401,9 +393,7 @@ public class GRestServiceEditorPane extends JPanel
     urldescPane.add(urldescVp, "span");
     paste.add(urldescPane, "span");
     urldescPane
-            .setToolTipText("<html>"
-                    + JvSwingUtils
-                            .wrapTooltip("Flat file representation of this rest service using the Really Simple Bioinformatics Service formalism"));
+            .setToolTipText(JvSwingUtils.wrapTooltip(false, MessageManager.getString("label.flat_file_representation")));
 
     parseRes = new JTextArea();
     parseResVp = new JScrollPane();
@@ -415,10 +405,7 @@ public class GRestServiceEditorPane extends JPanel
     parseWarnings.setBorder(new TitledBorder(MessageManager
             .getString("label.parsing_errors")));
     parseWarnings
-            .setToolTipText("<html>"
-                    + JvSwingUtils
-                            .wrapTooltip("Results of parsing the RSBS representation")
-                    + "</html>");
+            .setToolTipText(JvSwingUtils.wrapTooltip(false, MessageManager.getString("label.result_of_parsing_rsbs")));
     parseWarnings.add(parseResVp, "center");
     parseRes.setEditable(false);
     paste.add(parseWarnings, "span");
index 85088ce..3e6f91a 100755 (executable)
@@ -72,10 +72,10 @@ public class GSequenceLink extends Panel
     jLabel2.setText(MessageManager.getString("label.url"));
     jLabel2.setBounds(new Rectangle(17, 37, 54, 27));
     jLabel3.setFont(new java.awt.Font("Verdana", Font.ITALIC, 11));
-    jLabel3.setText("Use $SEQUENCE_ID$ or $SEQUENCE_ID=/<regex>/=$");
+    jLabel3.setText(MessageManager.getString("label.use_sequence_id_1"));
     jLabel3.setBounds(new Rectangle(21, 72, 351, 15));
     jLabel4.setFont(new java.awt.Font("Verdana", Font.ITALIC, 11));
-    jLabel4.setText("\nto embed sequence id in URL");
+    jLabel4.setText(MessageManager.getString("label.use_sequence_id_2"));
     jLabel4.setBounds(new Rectangle(21, 93, 351, 15));
     jPanel1.setBorder(BorderFactory.createEtchedBorder());
     jPanel1.setLayout(null);
@@ -121,8 +121,8 @@ public class GSequenceLink extends Panel
     JOptionPane
             .showInternalMessageDialog(
                     jalview.gui.Desktop.desktop,
-                    "Sequence URL must contain $SEQUENCE_ID$ or a regex $SEQUENCE_ID=/<regex>/=$",
-                    "URL not valid", JOptionPane.WARNING_MESSAGE);
+                    MessageManager.getString("warn.url_must_contain"),
+                    MessageManager.getString("label.invalid_url"), JOptionPane.WARNING_MESSAGE);
     return false;
   }
 
index 036d16a..acd83a8 100755 (executable)
@@ -403,8 +403,7 @@ public class Matrix
 
           if (iter == maxIter)
           {
-            throw new Exception("Too many iterations in tqli (" + maxIter
-                    + ")");
+            throw new Exception(MessageManager.formatMessage("exception.matrix_too_many_iteration", new String[]{"tqli", Integer.valueOf(maxIter).toString()}));
           }
           else
           {
@@ -653,8 +652,7 @@ public class Matrix
 
           if (iter == maxIter)
           {
-            throw new Exception("Too many iterations in tqli2 (max is "
-                    + maxIter + ")");
+              throw new Exception(MessageManager.formatMessage("exception.matrix_too_many_iteration", new String[]{"tqli2", Integer.valueOf(maxIter).toString()}));
           }
           else
           {
index a0e1ea1..c7d2f17 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -159,9 +161,11 @@ public class AlcodonFrame implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alcodMapList.size())
     {
-      throw new IndexOutOfBoundsException("getAlcodMap: Index value '"
-              + index + "' not in range [0.."
-              + (this._alcodMapList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getAlcodMap",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._alcodMapList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.AlcodMap) _alcodMapList
@@ -209,9 +213,11 @@ public class AlcodonFrame implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alcodonList.size())
     {
-      throw new IndexOutOfBoundsException("getAlcodon: Index value '"
-              + index + "' not in range [0.."
-              + (this._alcodonList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getAlcodon",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._alcodonList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.Alcodon) _alcodonList.get(index);
@@ -378,9 +384,11 @@ public class AlcodonFrame implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alcodMapList.size())
     {
-      throw new IndexOutOfBoundsException("setAlcodMap: Index value '"
-              + index + "' not in range [0.."
-              + (this._alcodMapList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setAlcodMap",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._alcodonList.size() - 1)).toString()
+          })); 
     }
 
     this._alcodMapList.set(index, vAlcodMap);
@@ -418,9 +426,11 @@ public class AlcodonFrame implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alcodonList.size())
     {
-      throw new IndexOutOfBoundsException("setAlcodon: Index value '"
-              + index + "' not in range [0.."
-              + (this._alcodonList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setAlcodon",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._alcodonList.size() - 1)).toString()
+        })); 
     }
 
     this._alcodonList.set(index, vAlcodon);
index f5cd880..0741387 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -373,10 +375,11 @@ public class Annotation implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationElementList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "getAnnotationElement: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._annotationElementList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getAnnotationElement",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._annotationElementList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.AnnotationElement) _annotationElementList
@@ -935,10 +938,11 @@ public class Annotation implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationElementList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "setAnnotationElement: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._annotationElementList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setAnnotationElement",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._annotationElementList.size() - 1)).toString()
+        })); 
     }
 
     this._annotationElementList.set(index, vAnnotationElement);
index 3bc1a9e..bbc5f67 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -224,9 +226,11 @@ public class Feature implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._otherDataList.size())
     {
-      throw new IndexOutOfBoundsException("getOtherData: Index value '"
-              + index + "' not in range [0.."
-              + (this._otherDataList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getOtherData",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._otherDataList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.OtherData) _otherDataList
@@ -467,9 +471,11 @@ public class Feature implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._otherDataList.size())
     {
-      throw new IndexOutOfBoundsException("setOtherData: Index value '"
-              + index + "' not in range [0.."
-              + (this._otherDataList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setOtherData",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._otherDataList.size() - 1)).toString()
+        })); 
     }
 
     this._otherDataList.set(index, vOtherData);
index 8c40929..14d9844 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -158,8 +160,11 @@ public class FeatureSettings implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._groupList.size())
     {
-      throw new IndexOutOfBoundsException("getGroup: Index value '" + index
-              + "' not in range [0.." + (this._groupList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getGroup",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._groupList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.Group) _groupList.get(index);
@@ -206,9 +211,11 @@ public class FeatureSettings implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._settingList.size())
     {
-      throw new IndexOutOfBoundsException("getSetting: Index value '"
-              + index + "' not in range [0.."
-              + (this._settingList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getSetting",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._settingList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.Setting) _settingList.get(index);
@@ -374,8 +381,11 @@ public class FeatureSettings implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._groupList.size())
     {
-      throw new IndexOutOfBoundsException("setGroup: Index value '" + index
-              + "' not in range [0.." + (this._groupList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setGroup",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._groupList.size() - 1)).toString()
+          })); 
     }
 
     this._groupList.set(index, vGroup);
@@ -413,9 +423,11 @@ public class FeatureSettings implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._settingList.size())
     {
-      throw new IndexOutOfBoundsException("setSetting: Index value '"
-              + index + "' not in range [0.."
-              + (this._settingList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setSetting",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._settingList.size() - 1)).toString()
+        })); 
     }
 
     this._settingList.set(index, vSetting);
index b909250..3a8dab2 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -535,8 +537,11 @@ public class JGroup implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._seqList.size())
     {
-      throw new IndexOutOfBoundsException("getSeq: Index value '" + index
-              + "' not in range [0.." + (this._seqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getSeq",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._seqList.size() - 1)).toString()
+          })); 
     }
 
     return (java.lang.String) _seqList.get(index);
@@ -1131,8 +1136,11 @@ public class JGroup implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._seqList.size())
     {
-      throw new IndexOutOfBoundsException("setSeq: Index value '" + index
-              + "' not in range [0.." + (this._seqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setSeq",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._seqList.size() - 1)).toString()
+        })); 
     }
 
     this._seqList.set(index, vSeq);
index 52aed9a..31a128e 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -296,9 +298,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._featuresList.size())
     {
-      throw new IndexOutOfBoundsException("getFeatures: Index value '"
-              + index + "' not in range [0.."
-              + (this._featuresList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getFeatures",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._featuresList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.Features) _featuresList
@@ -355,10 +359,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._hiddenSequencesList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "getHiddenSequences: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._hiddenSequencesList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getHiddenSequences",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._hiddenSequencesList.size() - 1)).toString()
+        })); 
     }
 
     return ((java.lang.Integer) _hiddenSequencesList.get(index)).intValue();
@@ -417,9 +422,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._pdbidsList.size())
     {
-      throw new IndexOutOfBoundsException("getPdbids: Index value '"
-              + index + "' not in range [0.."
-              + (this._pdbidsList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getPdbids",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._pdbidsList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.Pdbids) _pdbidsList.get(index);
@@ -702,9 +709,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._featuresList.size())
     {
-      throw new IndexOutOfBoundsException("setFeatures: Index value '"
-              + index + "' not in range [0.."
-              + (this._featuresList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setFeatures",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._featuresList.size() - 1)).toString()
+        })); 
     }
 
     this._featuresList.set(index, vFeatures);
@@ -753,10 +762,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._hiddenSequencesList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "setHiddenSequences: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._hiddenSequencesList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setHiddenSequences",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._hiddenSequencesList.size() - 1)).toString()
+          })); 
     }
 
     this._hiddenSequencesList.set(index, new java.lang.Integer(
@@ -806,9 +816,11 @@ public class JSeq implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._pdbidsList.size())
     {
-      throw new IndexOutOfBoundsException("setPdbids: Index value '"
-              + index + "' not in range [0.."
-              + (this._pdbidsList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setPdbids",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._pdbidsList.size() - 1)).toString()
+        })); 
     }
 
     this._pdbidsList.set(index, vPdbids);
index b40ab80..790a1ca 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -309,9 +311,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JGroupList.size())
     {
-      throw new IndexOutOfBoundsException("getJGroup: Index value '"
-              + index + "' not in range [0.."
-              + (this._JGroupList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getJGroup",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._JGroupList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.JGroup) _JGroupList.get(index);
@@ -358,8 +362,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JSeqList.size())
     {
-      throw new IndexOutOfBoundsException("getJSeq: Index value '" + index
-              + "' not in range [0.." + (this._JSeqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getJSeq",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._JSeqList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.JSeq) _JSeqList.get(index);
@@ -406,8 +413,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("getTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getJgetTreeSeq",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._treeList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.Tree) _treeList.get(index);
@@ -454,9 +464,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._userColoursList.size())
     {
-      throw new IndexOutOfBoundsException("getUserColours: Index value '"
-              + index + "' not in range [0.."
-              + (this._userColoursList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getUserColours",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._userColoursList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.UserColours) _userColoursList
@@ -504,9 +516,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._viewportList.size())
     {
-      throw new IndexOutOfBoundsException("getViewport: Index value '"
-              + index + "' not in range [0.."
-              + (this._viewportList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getViewport",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._viewportList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.Viewport) _viewportList
@@ -781,9 +795,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JGroupList.size())
     {
-      throw new IndexOutOfBoundsException("setJGroup: Index value '"
-              + index + "' not in range [0.."
-              + (this._JGroupList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setJGroup",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._JGroupList.size() - 1)).toString()
+        })); 
     }
 
     this._JGroupList.set(index, vJGroup);
@@ -821,8 +837,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._JSeqList.size())
     {
-      throw new IndexOutOfBoundsException("setJSeq: Index value '" + index
-              + "' not in range [0.." + (this._JSeqList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setJSeq",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._JSeqList.size() - 1)).toString()
+          })); 
     }
 
     this._JSeqList.set(index, vJSeq);
@@ -859,8 +878,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("setTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setTree",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._treeList.size() - 1)).toString()
+        })); 
     }
 
     this._treeList.set(index, vTree);
@@ -897,9 +919,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._userColoursList.size())
     {
-      throw new IndexOutOfBoundsException("setUserColours: Index value '"
-              + index + "' not in range [0.."
-              + (this._userColoursList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setUserColours",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._userColoursList.size() - 1)).toString()
+          })); 
     }
 
     this._userColoursList.set(index, vUserColours);
@@ -937,9 +961,11 @@ public class JalviewModelSequence implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._viewportList.size())
     {
-      throw new IndexOutOfBoundsException("setViewport: Index value '"
-              + index + "' not in range [0.."
-              + (this._viewportList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setViewport",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._viewportList.size() - 1)).toString()
+        })); 
     }
 
     this._viewportList.set(index, vViewport);
index 49f428a..e6ced25 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -120,9 +122,11 @@ public class JalviewUserColours implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._colourList.size())
     {
-      throw new IndexOutOfBoundsException("getColour: Index value '"
-              + index + "' not in range [0.."
-              + (this._colourList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getColour",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._colourList.size() - 1)).toString()
+          })); 
     }
 
     return (Colour) _colourList.get(index);
@@ -274,9 +278,11 @@ public class JalviewUserColours implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._colourList.size())
     {
-      throw new IndexOutOfBoundsException("setColour: Index value '"
-              + index + "' not in range [0.."
-              + (this._colourList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setColour",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._colourList.size() - 1)).toString()
+        })); 
     }
 
     this._colourList.set(index, vColour);
index a43e797..32e8ce2 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -220,9 +222,11 @@ public class MapListType implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._mapListFromList.size())
     {
-      throw new IndexOutOfBoundsException("getMapListFrom: Index value '"
-              + index + "' not in range [0.."
-              + (this._mapListFromList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getMapListFrom",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._mapListFromList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.MapListFrom) _mapListFromList
@@ -270,9 +274,11 @@ public class MapListType implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._mapListToList.size())
     {
-      throw new IndexOutOfBoundsException("getMapListTo: Index value '"
-              + index + "' not in range [0.."
-              + (this._mapListToList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getMapListTo",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._mapListToList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.MapListTo) _mapListToList
@@ -492,9 +498,11 @@ public class MapListType implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._mapListFromList.size())
     {
-      throw new IndexOutOfBoundsException("setMapListFrom: Index value '"
-              + index + "' not in range [0.."
-              + (this._mapListFromList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setMapListFrom",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._mapListFromList.size() - 1)).toString()
+          })); 
     }
 
     this._mapListFromList.set(index, vMapListFrom);
@@ -532,9 +540,11 @@ public class MapListType implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._mapListToList.size())
     {
-      throw new IndexOutOfBoundsException("setMapListTo: Index value '"
-              + index + "' not in range [0.."
-              + (this._mapListToList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setMapListTo",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._mapListToList.size() - 1)).toString()
+        })); 
     }
 
     this._mapListToList.set(index, vMapListTo);
index 8644745..a558e12 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -148,9 +150,11 @@ public class Pdbentry implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._items.size())
     {
-      throw new IndexOutOfBoundsException("getPdbentryItem: Index value '"
-              + index + "' not in range [0.." + (this._items.size() - 1)
-              + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getPdbentryItem",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._items.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.PdbentryItem) _items.get(index);
@@ -316,9 +320,11 @@ public class Pdbentry implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._items.size())
     {
-      throw new IndexOutOfBoundsException("setPdbentryItem: Index value '"
-              + index + "' not in range [0.." + (this._items.size() - 1)
-              + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setPdbentryItem",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._items.size() - 1)).toString()
+        })); 
     }
 
     this._items.set(index, vPdbentryItem);
index 20bbac8..b1bbf11 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.schemabinding.version2;
 
+import jalview.util.MessageManager;
+
 /**
  * Class PdbentryItem.
  * 
@@ -106,9 +108,11 @@ public class PdbentryItem implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._propertyList.size())
     {
-      throw new IndexOutOfBoundsException("getProperty: Index value '"
-              + index + "' not in range [0.."
-              + (this._propertyList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getProperty",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._propertyList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.Property) _propertyList
@@ -189,9 +193,11 @@ public class PdbentryItem implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._propertyList.size())
     {
-      throw new IndexOutOfBoundsException("setProperty: Index value '"
-              + index + "' not in range [0.."
-              + (this._propertyList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setProperty",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._propertyList.size() - 1)).toString()
+        })); 
     }
 
     this._propertyList.set(index, vProperty);
index b491cf0..bf700f9 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -115,10 +117,11 @@ public class Pdbids extends jalview.schemabinding.version2.Pdbentry
     // check bounds for index
     if (index < 0 || index >= this._structureStateList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "getStructureState: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._structureStateList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getStructureState",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._structureStateList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.StructureState) _structureStateList
@@ -255,10 +258,11 @@ public class Pdbids extends jalview.schemabinding.version2.Pdbentry
     // check bounds for index
     if (index < 0 || index >= this._structureStateList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "setStructureState: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._structureStateList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setStructureState",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._structureStateList.size() - 1)).toString()
+        })); 
     }
 
     this._structureStateList.set(index, vStructureState);
index 4ada896..54f2e30 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -120,8 +122,11 @@ public class Sequence extends jalview.schemabinding.version2.SequenceType
     // check bounds for index
     if (index < 0 || index >= this._DBRefList.size())
     {
-      throw new IndexOutOfBoundsException("getDBRef: Index value '" + index
-              + "' not in range [0.." + (this._DBRefList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getDBRef",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._DBRefList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.DBRef) _DBRefList.get(index);
@@ -267,8 +272,11 @@ public class Sequence extends jalview.schemabinding.version2.SequenceType
     // check bounds for index
     if (index < 0 || index >= this._DBRefList.size())
     {
-      throw new IndexOutOfBoundsException("setDBRef: Index value '" + index
-              + "' not in range [0.." + (this._DBRefList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setDBRef",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._DBRefList.size() - 1)).toString()
+        })); 
     }
 
     this._DBRefList.set(index, vDBRef);
index fe146fa..d058ad5 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -264,9 +266,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alcodonFrameList.size())
     {
-      throw new IndexOutOfBoundsException("getAlcodonFrame: Index value '"
-              + index + "' not in range [0.."
-              + (this._alcodonFrameList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getAlcodonFrame",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._alcodonFrameList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.AlcodonFrame) _alcodonFrameList
@@ -314,9 +318,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationList.size())
     {
-      throw new IndexOutOfBoundsException("getAnnotation: Index value '"
-              + index + "' not in range [0.."
-              + (this._annotationList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getAnnotation",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._alcodonFrameList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.Annotation) _annotationList
@@ -387,9 +393,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceList.size())
     {
-      throw new IndexOutOfBoundsException("getSequence: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getSequence",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._sequenceList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.Sequence) _sequenceList
@@ -438,10 +446,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceSetPropertiesList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "getSequenceSetProperties: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._sequenceSetPropertiesList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getSequenceSetProperties",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._sequenceSetPropertiesList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.SequenceSetProperties) _sequenceSetPropertiesList
@@ -677,9 +686,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._alcodonFrameList.size())
     {
-      throw new IndexOutOfBoundsException("setAlcodonFrame: Index value '"
-              + index + "' not in range [0.."
-              + (this._alcodonFrameList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setAlcodonFrame",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._alcodonFrameList.size() - 1)).toString()
+          })); 
     }
 
     this._alcodonFrameList.set(index, vAlcodonFrame);
@@ -717,9 +728,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._annotationList.size())
     {
-      throw new IndexOutOfBoundsException("setAnnotation: Index value '"
-              + index + "' not in range [0.."
-              + (this._annotationList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setAnnotation",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._annotationList.size() - 1)).toString()
+        })); 
     }
 
     this._annotationList.set(index, vAnnotation);
@@ -782,9 +795,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceList.size())
     {
-      throw new IndexOutOfBoundsException("setSequence: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setSequence",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._sequenceList.size() - 1)).toString()
+          })); 
     }
 
     this._sequenceList.set(index, vSequence);
@@ -823,10 +838,11 @@ public class SequenceSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceSetPropertiesList.size())
     {
-      throw new IndexOutOfBoundsException(
-              "setSequenceSetProperties: Index value '" + index
-                      + "' not in range [0.."
-                      + (this._sequenceSetPropertiesList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setSequenceSetProperties",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._sequenceSetPropertiesList.size() - 1)).toString()
+        })); 
     }
 
     this._sequenceSetPropertiesList.set(index, vSequenceSetProperties);
index 2a7d463..7f0c216 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -156,9 +158,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceSetList.size())
     {
-      throw new IndexOutOfBoundsException("getSequenceSet: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceSetList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getSequenceSet",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._sequenceSetList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.SequenceSet) _sequenceSetList
@@ -205,8 +209,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("getTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getTree",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._treeList.size() - 1)).toString()
+        })); 
     }
 
     return (java.lang.String) _treeList.get(index);
@@ -370,9 +377,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._sequenceSetList.size())
     {
-      throw new IndexOutOfBoundsException("setSequenceSet: Index value '"
-              + index + "' not in range [0.."
-              + (this._sequenceSetList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setSequenceSet",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._sequenceSetList.size() - 1)).toString()
+          })); 
     }
 
     this._sequenceSetList.set(index, vSequenceSet);
@@ -409,8 +418,11 @@ public class VAMSAS implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._treeList.size())
     {
-      throw new IndexOutOfBoundsException("setTree: Index value '" + index
-              + "' not in range [0.." + (this._treeList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setTree",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._treeList.size() - 1)).toString()
+        })); 
     }
 
     this._treeList.set(index, vTree);
index 03bd2a9..1faf480 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -845,9 +847,11 @@ public class Viewport implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._calcIdParamList.size())
     {
-      throw new IndexOutOfBoundsException("getCalcIdParam: Index value '"
-              + index + "' not in range [0.."
-              + (this._calcIdParamList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getCalcIdParam",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._calcIdParamList.size() - 1)).toString()
+          })); 
     }
 
     return (jalview.schemabinding.version2.CalcIdParam) _calcIdParamList
@@ -995,9 +999,11 @@ public class Viewport implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._hiddenColumnsList.size())
     {
-      throw new IndexOutOfBoundsException("getHiddenColumns: Index value '"
-              + index + "' not in range [0.."
-              + (this._hiddenColumnsList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "getHiddenColumns",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._hiddenColumnsList.size() - 1)).toString()
+        })); 
     }
 
     return (jalview.schemabinding.version2.HiddenColumns) _hiddenColumnsList
@@ -2121,9 +2127,11 @@ public class Viewport implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._calcIdParamList.size())
     {
-      throw new IndexOutOfBoundsException("setCalcIdParam: Index value '"
-              + index + "' not in range [0.."
-              + (this._calcIdParamList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "setCalcIdParam",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._calcIdParamList.size() - 1)).toString()
+          })); 
     }
 
     this._calcIdParamList.set(index, vCalcIdParam);
@@ -2280,9 +2288,11 @@ public class Viewport implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._hiddenColumnsList.size())
     {
-      throw new IndexOutOfBoundsException("setHiddenColumns: Index value '"
-              + index + "' not in range [0.."
-              + (this._hiddenColumnsList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setHiddenColumns",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._hiddenColumnsList.size() - 1)).toString()
+        })); 
     }
 
     this._hiddenColumnsList.set(index, vHiddenColumns);
index 0cf7c49..822a175 100644 (file)
@@ -24,6 +24,8 @@ package jalview.schemabinding.version2;
 //- Imported classes and packages -/
 //---------------------------------/
 
+import jalview.util.MessageManager;
+
 import org.exolab.castor.xml.Marshaller;
 import org.exolab.castor.xml.Unmarshaller;
 
@@ -183,9 +185,11 @@ public class WebServiceParameterSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._serviceURLList.size())
     {
-      throw new IndexOutOfBoundsException("getServiceURL: Index value '"
-              + index + "' not in range [0.."
-              + (this._serviceURLList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                         "getServiceURL",
+                         Integer.valueOf(index).toString(),
+                         Integer.valueOf((this._serviceURLList.size() - 1)).toString()
+          })); 
     }
 
     return (java.lang.String) _serviceURLList.get(index);
@@ -373,9 +377,11 @@ public class WebServiceParameterSet implements java.io.Serializable
     // check bounds for index
     if (index < 0 || index >= this._serviceURLList.size())
     {
-      throw new IndexOutOfBoundsException("setServiceURL: Index value '"
-              + index + "' not in range [0.."
-              + (this._serviceURLList.size() - 1) + "]");
+        throw new IndexOutOfBoundsException(MessageManager.formatMessage("exception.index_value_not_in_range", new String[]{
+                 "setServiceURL",
+                 Integer.valueOf(index).toString(),
+                 Integer.valueOf((this._serviceURLList.size() - 1)).toString()
+        })); 
     }
 
     this._serviceURLList.set(index, vServiceURL);
index 609e741..47b8fbd 100755 (executable)
@@ -25,6 +25,7 @@ import jalview.analysis.Conservation;
 import jalview.datamodel.AnnotatedCollectionI;
 import jalview.datamodel.SequenceCollectionI;
 import jalview.datamodel.SequenceI;
+import jalview.util.MessageManager;
 
 import java.awt.Color;
 import java.util.Hashtable;
@@ -323,9 +324,7 @@ public class ResidueColourScheme implements ColourSchemeI
       return getClass().newInstance();
     } catch (Exception q)
     {
-      throw new Error(
-              "Serious implementation error: cannot duplicate colourscheme "
-                      + getClass().getName(), q);
+      throw new Error(MessageManager.formatMessage("error.implementation_error_cannot_duplicate_colour_scheme", new String[]{getClass().getName()}), q);
     }
   }
 }
index c0c559a..73a5905 100644 (file)
@@ -28,6 +28,7 @@ import jalview.analysis.*;
 import jalview.api.AlignmentViewPanel;
 import jalview.api.StructureSelectionManagerProvider;
 import jalview.datamodel.*;
+import jalview.util.MessageManager;
 
 public class StructureSelectionManager
 {
@@ -68,9 +69,8 @@ public class StructureSelectionManager
       {
         if (instances != null)
         {
-          throw new Error(
-                  "Implementation error. Structure selection manager's context is 'null'",
-                  new NullPointerException("SSM context is null"));
+          throw new Error(MessageManager.getString("error.implementation_error_structure_selection_manager_null"),
+                  new NullPointerException(MessageManager.getString("exception.ssm_context_is_null")));
         }
         else
         {
index 9aaa307..871b480 100644 (file)
@@ -223,8 +223,7 @@ public class AWTConsole extends WindowAdapter implements WindowListener,
       } catch (InterruptedException ie)
       {
       }
-      throw new NullPointerException(
-              "Application test: throwing an NullPointerException It should arrive at the console");
+      throw new NullPointerException(MessageManager.getString("exception.application_test_npe"));
     }
 
   }
index a0f9523..60e2fed 100755 (executable)
@@ -702,14 +702,14 @@ public class BrowserLauncher
   {
     if (!loadedWithoutErrors)
     {
-      throw new IOException("Exception in finding browser: " + errorMessage);
+      throw new IOException(MessageManager.formatMessage("exception.browser_not_found", new String[]{errorMessage}));
     }
 
     Object browser = locateBrowser();
 
     if (browser == null)
     {
-      throw new IOException("Unable to locate browser: " + errorMessage);
+        throw new IOException(MessageManager.formatMessage("exception.browser_unable_to_locate", new String[]{errorMessage}));
     }
 
     switch (jvm)
@@ -728,19 +728,13 @@ public class BrowserLauncher
         {});
       } catch (InvocationTargetException ite)
       {
-        throw new IOException(
-                "InvocationTargetException while creating AEDesc: "
-                        + ite.getMessage());
+        throw new IOException(MessageManager.formatMessage("exception.invocation_target_exception_creating_aedesc", new String[]{ite.getMessage()}));
       } catch (IllegalAccessException iae)
       {
-        throw new IOException(
-                "IllegalAccessException while building AppleEvent: "
-                        + iae.getMessage());
+         throw new IOException(MessageManager.formatMessage("exception.illegal_access_building_apple_evt", new String[]{iae.getMessage()}));
       } catch (InstantiationException ie)
       {
-        throw new IOException(
-                "InstantiationException while creating AEDesc: "
-                        + ie.getMessage());
+         throw new IOException(MessageManager.formatMessage("exception.illegal_access_building_apple_evt", new String[]{ie.getMessage()}));
       } finally
       {
         aeDesc = null; // Encourage it to get disposed if it was created
@@ -778,13 +772,12 @@ public class BrowserLauncher
         }
         else
         {
-          throw new IOException("Unable to launch URL: " + result);
+          throw new IOException(MessageManager.formatMessage("exception.unable_to_launch_url", new String[]{Integer.valueOf(result).toString()}));
         }
       }
       else
       {
-        throw new IOException(
-                "Unable to create an Internet Config instance: " + result);
+        throw new IOException(MessageManager.formatMessage("exception.unable_to_create_internet_config", new String[]{Integer.valueOf(result).toString()}));
       }
 
       break;
@@ -797,14 +790,10 @@ public class BrowserLauncher
         { url });
       } catch (InvocationTargetException ite)
       {
-        throw new IOException(
-                "InvocationTargetException while calling openURL: "
-                        + ite.getMessage());
+        throw new IOException(MessageManager.formatMessage("exception.invocation_target_calling_url", new String[]{ite.getMessage()}));
       } catch (IllegalAccessException iae)
       {
-        throw new IOException(
-                "IllegalAccessException while calling openURL: "
-                        + iae.getMessage());
+          throw new IOException(MessageManager.formatMessage("exception.illegal_access_calling_url", new String[]{iae.getMessage()}));
       }
 
       break;
@@ -829,9 +818,7 @@ public class BrowserLauncher
         process.exitValue();
       } catch (InterruptedException ie)
       {
-        throw new IOException(
-                "InterruptedException while launching browser: "
-                        + ie.getMessage());
+          throw new IOException(MessageManager.formatMessage("exception.interrupted_launching_browser", new String[]{ie.getMessage()}));
       }
 
       break;
@@ -870,9 +857,7 @@ public class BrowserLauncher
         }
       } catch (InterruptedException ie)
       {
-        throw new IOException(
-                "InterruptedException while launching browser: "
-                        + ie.getMessage());
+          throw new IOException(MessageManager.formatMessage("exception.interrupted_launching_browser", new String[]{ie.getMessage()}));
       }
 
       break;
index d6965f5..4cc888d 100755 (executable)
@@ -418,11 +418,15 @@ public class DBRefUtils
         // check for chaincode and mapping
         // PFAM style stockhom PDB citation
         com.stevesoft.pat.Regex r = new com.stevesoft.pat.Regex(
-                "([0-9][0-9A-Za-z]{3})\\s*(.?)\\s*;([0-9]+)-([0-9]+)");
+                "([0-9][0-9A-Za-z]{3})\\s*(.?)\\s*;\\s*([0-9]+)-([0-9]+)");
         if (r.search(acn.trim()))
         {
           String pdbid = r.stringMatched(1);
           String chaincode = r.stringMatched(2);
+          if (chaincode==null)
+          {
+            chaincode = " ";
+          }
           String mapstart = r.stringMatched(3);
           String mapend = r.stringMatched(4);
           if (chaincode.equals(" "))
@@ -433,8 +437,11 @@ public class DBRefUtils
           ref = new DBRefEntry(locsrc, version, pdbid + chaincode);
           PDBEntry pdbr = new PDBEntry();
           pdbr.setId(pdbid);
+          pdbr.setProperty(new Hashtable());
           pdbr.getProperty().put("CHAIN", chaincode);
           seq.addPDBId(pdbr);
+        } else {
+          System.err.println("Malformed PDB DR line:"+acn);
         }
       }
       else
index ea3f69f..e8af4cd 100644 (file)
@@ -396,8 +396,7 @@ public class GroupUrlLink
     { dsstring });
     if (idstrings.length != seqstrings.length)
     {
-      throw new Error(
-              "idstrings and seqstrings contain one string each per sequence.");
+      throw new Error(MessageManager.getString("error.idstring_seqstrings_only_one_per_sequence"));
     }
     return rstrings;
   }
@@ -487,18 +486,14 @@ public class GroupUrlLink
         {
           if (maxs != idseq[i].length)
           {
-            throw new Error(
-                    "Cannot have mixed length replacement vectors. Replacement vector for "
-                            + (mtch[i]) + " is " + idseq[i].length
-                            + " strings long, and have already seen a "
-                            + maxs + " length vector.");
+            throw new Error(MessageManager.formatMessage("error.cannot_have_mixed_length_replacement_vectors",
+                               new String[]{(mtch[i]), Integer.valueOf(idseq[i].length).toString(),Integer.valueOf(maxs).toString()}));
           }
         }
       }
       else
       {
-        throw new Error(
-                "Cannot have zero length vector of replacement strings - either 1 value or n values.");
+        throw new Error(MessageManager.getString("error.cannot_have_zero_length_vector_replacement_strings"));
       }
     }
     // iterate through input, collating segments to be inserted into url
index 7ab1781..edb56a9 100644 (file)
@@ -29,6 +29,7 @@ import jalview.datamodel.SequenceI;
 import jalview.gui.AlignFrame;
 import jalview.gui.WebserviceInfo;
 import jalview.gui.FeatureRenderer.FeatureRendererSettings;
+import jalview.util.MessageManager;
 
 public abstract class AWSThread extends Thread
 {
@@ -123,8 +124,8 @@ public abstract class AWSThread extends Thread
           } catch (Exception ex)
           {
             // Deal with Transaction exceptions
-            wsInfo.appendProgressText(jobs[j].jobnum, "\n" + WebServiceName
-                    + " Server exception!\n" + ex.getMessage());
+            wsInfo.appendProgressText(jobs[j].jobnum, 
+                       MessageManager.formatMessage("info.server_exception", new String[]{WebServiceName,ex.getMessage()}));
             // always output the exception's stack trace to the log
             Cache.log.warn(WebServiceName + " job(" + jobs[j].jobnum
                     + ") Server exception.");
@@ -189,7 +190,7 @@ public abstract class AWSThread extends Thread
       Cache.log
               .debug("WebServiceJob poll loop finished with no jobs created.");
       wsInfo.setStatus(wsInfo.STATE_STOPPED_ERROR);
-      wsInfo.appendProgressText("No jobs ran.");
+      wsInfo.appendProgressText(MessageManager.getString("info.no_jobs_ran"));
       wsInfo.setFinishedNoResults();
     }
   }
index ebf3a7d..f5789ea 100644 (file)
@@ -283,11 +283,11 @@ public class DBRefFetcher implements Runnable
   {
     if (dbSources == null)
     {
-      throw new Error("Implementation error. Must initialise dbSources");
+      throw new Error(MessageManager.getString("error.implementation_error_must_init_dbsources"));
     }
     running = true;
     long startTime = System.currentTimeMillis();
-    af.setProgressBar("Fetching db refs", startTime);
+    af.setProgressBar(MessageManager.getString("status.fetching_db_refs"), startTime);
     try
     {
       if (Cache.getDefault("DBREFFETCH_USEPICR", false))
index ff715ba..8a7bcbc 100644 (file)
@@ -27,6 +27,7 @@ import jalview.datamodel.SequenceI;
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
 import jalview.gui.FeatureSettings;
+import jalview.util.MessageManager;
 import jalview.util.UrlLink;
 import jalview.ws.dbsources.das.api.DasSourceRegistryI;
 import jalview.ws.dbsources.das.api.jalviewSourceI;
@@ -204,9 +205,8 @@ public class DasSequenceFeatureFetcher
         reply = JOptionPane
                 .showInternalConfirmDialog(
                         Desktop.desktop,
-                        "Do you want Jalview to find\n"
-                                + "Uniprot Accession ids for given sequence names?",
-                        "Find Uniprot Accession Ids",
+                        MessageManager.getString("info.you_want_jalview_to_find_uniprot_accessions"),
+                        MessageManager.getString("label.find_uniprot_accession_ids"),
                         JOptionPane.YES_NO_OPTION,
                         JOptionPane.QUESTION_MESSAGE);
       }
@@ -264,7 +264,7 @@ public class DasSequenceFeatureFetcher
     startTime = System.currentTimeMillis();
     if (af != null)
     {
-      af.setProgressBar("Fetching DAS Sequence Features", startTime);
+      af.setProgressBar(MessageManager.getString("status.fetching_das_sequence_features"), startTime);
     }
     if (sourceRegistry == null)
     {
@@ -537,7 +537,7 @@ public class DasSequenceFeatureFetcher
 
     if (af != null)
     {
-      af.setProgressBar("No DAS Sources Active", startTime);
+      af.setProgressBar(MessageManager.getString("status.no_das_sources_active"), startTime);
     }
     if (getFeatSettings() != null)
     {
@@ -567,7 +567,7 @@ public class DasSequenceFeatureFetcher
   {
     if (af != null)
     {
-      af.setProgressBar("DAS Feature Fetching Cancelled", startTime);
+      af.setProgressBar(MessageManager.getString("status.das_feature_fetching_cancelled"), startTime);
     }
     cancelled = true;
   }
@@ -582,7 +582,7 @@ public class DasSequenceFeatureFetcher
     if (!cancelled && af != null)
     {
       // only update the progress bar if we've completed the fetch normally
-      af.setProgressBar("DAS Feature Fetching Complete", startTime);
+      af.setProgressBar(MessageManager.getString("status.das_feature_fetching_complete"), startTime);
     }
 
     if (af != null && af.featureSettings != null)
index c048f45..693c888 100644 (file)
@@ -28,6 +28,7 @@ import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
 import jalview.gui.JvSwingUtils;
 import jalview.util.GroupUrlLink;
+import jalview.util.MessageManager;
 import jalview.util.GroupUrlLink.UrlStringTooLongException;
 
 import java.awt.Component;
@@ -334,12 +335,7 @@ public class EnfinEnvision2OneWay extends DefaultHandler implements
     {
       dbname = "";
     }
-    item.setToolTipText("<html>"
-            + JvSwingUtils.wrapTooltip("Submit " + i + " " + dbname + " "
-                    + (seqsorids ? "sequence" : "sequence id")
-                    + (i > 1 ? "s" : "")
-
-                    + " to<br/>" + descr) + "</html>");
+    item.setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager.formatMessage("label.submit_sequence", new String[]{Integer.valueOf(i).toString(), dbname, (seqsorids ? "sequence" : "sequence id"), (i > 1 ? "s" : "")})));
     item.addActionListener(new java.awt.event.ActionListener()
     {
       public void actionPerformed(ActionEvent e)
@@ -380,9 +376,8 @@ public class EnfinEnvision2OneWay extends DefaultHandler implements
       JOptionPane
               .showInternalMessageDialog(
                       Desktop.desktop,
-                      "Unixers: Couldn't find default web browser."
-                              + "\nAdd the full path to your browser in Preferences.",
-                      "Web browser not found", JOptionPane.WARNING_MESSAGE);
+                      MessageManager.getString("label.web_browser_not_found_unix"),
+                      MessageManager.getString("label.web_browser_not_found"), JOptionPane.WARNING_MESSAGE);
 
       ex.printStackTrace();
     }
@@ -441,7 +436,7 @@ public class EnfinEnvision2OneWay extends DefaultHandler implements
     // menu appears asap
     // sequence only URLs
     // ID/regex match URLs
-    JMenu groupLinksMenu = new JMenu("Group Link");
+    JMenu groupLinksMenu = new JMenu(MessageManager.getString("action.group_link"));
     String[][] idandseqs = GroupUrlLink.formStrings(seqs);
     Hashtable commonDbrefs = new Hashtable();
     for (int sq = 0; sq < seqs.length; sq++)
@@ -540,8 +535,8 @@ public class EnfinEnvision2OneWay extends DefaultHandler implements
         // three types of url that might be
         // created.
         wflinkMenus = new JMenu[]
-        { null, new JMenu("IDS"), new JMenu("Sequences"),
-            new JMenu("IDS and Sequences") };
+        { null, new JMenu(MessageManager.getString("action.ids")), new JMenu(MessageManager.getString("action.sequences")),
+            new JMenu(MessageManager.getString("action.ids_sequences")) };
         gurlMenus.put(label, wflinkMenus);
       }
 
index ee8eb79..ec5c62d 100644 (file)
@@ -24,6 +24,7 @@ import jalview.datamodel.Alignment;
 import jalview.datamodel.AlignmentI;
 import jalview.datamodel.SequenceI;
 import jalview.datamodel.xdb.embl.EmblEntry;
+import jalview.util.MessageManager;
 import jalview.ws.ebi.EBIFetchClient;
 
 import java.io.File;
@@ -65,8 +66,7 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
     } catch (Exception e)
     {
       stopQuery();
-      throw new Exception("EBI EMBL XML retrieval failed on "
-              + emprefx.toLowerCase() + ":" + query.trim(), e);
+      throw new Exception(MessageManager.formatMessage("exception.ebiembl_retrieval_failed_on", new String[]{emprefx.toLowerCase(),query.trim()}), e);
     }
     return getEmblSequenceRecords(emprefx, query, reply);
   }
@@ -98,8 +98,7 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
       }
       else
       {
-        result.append("# No EMBL record retrieved for "
-                + emprefx.toLowerCase() + ":" + query.trim());
+        result.append(MessageManager.formatMessage("label.no_embl_record_found", new String[]{emprefx.toLowerCase(),query.trim()}));
       }
     }
     if (efile != null)
@@ -153,8 +152,7 @@ public abstract class EmblXmlSource extends EbiFileRetrievedProxy
     if (seqs != null && seqs.length > 0)
     {
       al = new Alignment(seqs);
-      result.append("# Successfully parsed the " + emprefx
-              + " queries into an Alignment");
+      result.append(MessageManager.formatMessage("label.embl_successfully_parsed", new String[]{emprefx}));
       results = result;
     }
     stopQuery();
index 1c6c015..f222aaa 100644 (file)
@@ -21,6 +21,7 @@
 package jalview.ws.dbsources;
 
 import jalview.datamodel.Alignment;
+import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.DBRefEntry;
 import jalview.datamodel.DBRefSource;
 import jalview.datamodel.PDBEntry;
@@ -37,6 +38,7 @@ import com.stevesoft.pat.Regex;
 
 import jalview.datamodel.AlignmentI;
 import jalview.io.FormatAdapter;
+import jalview.util.MessageManager;
 import jalview.ws.ebi.EBIFetchClient;
 import jalview.ws.seqfetcher.DbSourceProxy;
 
@@ -192,13 +194,19 @@ public class Pdb extends EbiFileRetrievedProxy implements DbSourceProxy
         for (SequenceI pdbcs : toremove)
         {
           pdbfile.deleteSequence(pdbcs);
+          if (pdbcs.getAnnotation()!=null)
+          {
+            for (AlignmentAnnotation aa: pdbcs.getAnnotation())
+            {
+              pdbfile.deleteAnnotation(aa);
+            }
+          }
         }
       }
 
       if (pdbfile == null || pdbfile.getHeight() < 1)
       {
-        throw new Exception("No PDB Records for " + id + " chain "
-                + ((chain == null) ? "' '" : chain));
+        throw new Exception(MessageManager.formatMessage("exception.no_pdb_records_for_chain", new String[]{id, ((chain == null) ? "' '" : chain)}));
       }
 
     } catch (Exception ex) // Problem parsing PDB file
index b9d778b..cb5705e 100644 (file)
@@ -39,6 +39,7 @@ import org.biodas.jdas.schema.sources.VERSION;
 
 import com.stevesoft.pat.Regex;
 
+import jalview.util.MessageManager;
 import jalview.ws.dbsources.das.api.jalviewSourceI;
 import jalview.ws.seqfetcher.*;
 import jalview.bin.Cache;
@@ -100,8 +101,7 @@ public class DasSequenceSource extends DbSourceProxyImpl implements
     if (!(jsrc = new JalviewSource(source, connprops, false))
             .isSequenceSource())
     {
-      throw new Exception("Source " + source.getTitle()
-              + " does not support the sequence command.");
+      throw new Exception(MessageManager.formatMessage("exception.das_source_doesnt_support_sequence_command", new String[]{source.getTitle()}));
     }
     this.tier = 1 + ((jsrc.isLocal() || jsrc.isReferenceSource()) ? 0 : 1);
     this.source = source;
index d260b9e..c994fd5 100644 (file)
@@ -37,6 +37,7 @@ import org.biodas.jdas.schema.sources.PROP;
 import org.biodas.jdas.schema.sources.SOURCE;
 import org.biodas.jdas.schema.sources.VERSION;
 
+import jalview.util.MessageManager;
 import jalview.ws.dbsources.das.api.jalviewSourceI;
 import jalview.ws.seqfetcher.DbSourceProxy;
 
@@ -346,7 +347,7 @@ public class JalviewSource implements jalviewSourceI
         int p = cap.getQueryUri().lastIndexOf(capname);
         if (p < -1)
         {
-          throw new Exception("Invalid das source: " + source.getUri());
+          throw new Exception(MessageManager.formatMessage("exception.invalid_das_source", new String[]{source.getUri()}));
         }
         if (cap.getQueryUri().charAt(p) == '/')
         {
index f5f9190..fe9e28f 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.ws.ebi;
 
+import jalview.util.MessageManager;
+
 import java.io.BufferedInputStream;
 import java.io.BufferedReader;
 import java.io.File;
@@ -56,7 +58,7 @@ public class EBIFetchClient
   public String[] getSupportedDBs()
   {
     // TODO - implement rest call for dbfetch getSupportedDBs
-    throw new Error("Not yet implemented");
+    throw new Error(MessageManager.getString("error.not_yet_implemented"));
   }
 
   /**
@@ -67,7 +69,7 @@ public class EBIFetchClient
   public String[] getSupportedFormats()
   {
     // TODO - implement rest call for dbfetch getSupportedFormats
-    throw new Error("Not yet implemented");
+    throw new Error(MessageManager.getString("error.not_yet_implemented"));
   }
 
   /**
@@ -78,7 +80,7 @@ public class EBIFetchClient
   public String[] getSupportedStyles()
   {
     // TODO - implement rest call for dbfetch getSupportedStyles
-    throw new Error("Not yet implemented");
+    throw new Error(MessageManager.getString("error.not_yet_implemented"));
   }
 
   public File fetchDataAsFile(String ids, String f, String s)
index 465c5fc..4502b39 100644 (file)
@@ -25,6 +25,7 @@ import jalview.datamodel.AlignmentI;
 import jalview.io.FileParse;
 import jalview.io.FormatAdapter;
 import jalview.io.InputStreamParser;
+import jalview.util.MessageManager;
 
 import java.io.BufferedReader;
 import java.io.FileReader;
@@ -105,8 +106,7 @@ public class Annotate3D
       }
       else
       {
-        throw new IOException(
-                "Unexpected exception when handling RNAML translation of PDB data",
+        throw new IOException(MessageManager.getString("exception.unexpected_handling_rnaml_translation_for_pdb"),
                 x);
       }
     }
index 3229cdc..629b3d6 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.ws.jws1;
 
+import jalview.util.MessageManager;
+
 import java.util.*;
 
 import javax.swing.*;
@@ -192,21 +194,21 @@ public class Discoverer implements Runnable
                     "Edgar, Robert C. (2004), MUSCLE: multiple sequence alignment "
                             + "with high accuracy and high throughput, Nucleic Acids Research 32(5), 1792-97.",
                     "http://www.compbio.dundee.ac.uk/JalviewWS/services/MuscleWS",
-                    "Muscle Multiple Protein Sequence Alignment"),
+                    MessageManager.getString("label.muscle_multiple_protein_sequence_alignment")),
             new ServiceHandle(
                     "MsaWS",
                     "Katoh, K., K. Kuma, K., Toh, H.,  and Miyata, T. (2005) "
                             + "\"MAFFT version 5: improvement in accuracy of multiple sequence alignment.\""
                             + " Nucleic Acids Research, 33 511-518",
                     "http://www.compbio.dundee.ac.uk/JalviewWS/services/MafftWS",
-                    "MAFFT Multiple Sequence Alignment"),
+                    MessageManager.getString("label.mafft_multiple_sequence_alignment")),
             new ServiceHandle(
                     "MsaWS",
                     "Thompson, J.D., Higgins, D.G. and Gibson, T.J. (1994) CLUSTAL W: improving the sensitivity of progressive multiple"
                             + " sequence alignment through sequence weighting, position specific gap penalties and weight matrix choice."
                             + " Nucleic Acids Research, 22 4673-4680",
                     "http://www.compbio.dundee.ac.uk/JalviewWS/services/ClustalWS",
-                    "ClustalW Multiple Sequence Alignment"),
+                    MessageManager.getString("label.clustalw_multiple_sequence_alignment")),
             new ServiceHandle(
                     "SecStrPred",
                     "Cole C., Barber J. D., Barton G.J (2008) "
@@ -248,8 +250,8 @@ public class Discoverer implements Runnable
           JOptionPane
                   .showMessageDialog(
                           jalview.gui.Desktop.desktop,
-                          "Please set up your proxy settings in the 'Connections' tab of the Preferences window",
-                          "Proxy Authorization Failed",
+                          MessageManager.getString("label.set_proxy_settings"),
+                          MessageManager.getString("label.proxy_authorization_failed"),
                           JOptionPane.WARNING_MESSAGE);
         }
       }
index e96ae34..1a96464 100644 (file)
@@ -31,6 +31,7 @@ import jalview.analysis.*;
 import jalview.bin.*;
 import jalview.datamodel.*;
 import jalview.gui.*;
+import jalview.util.MessageManager;
 
 public class JPredClient extends WS1Client
 {
@@ -143,8 +144,7 @@ public class JPredClient extends WS1Client
     {
       if (!msa && msf.length > 1)
       {
-        throw new Error(
-                "Implementation Error! Multiple single sequence prediction jobs are not yet supported.");
+        throw new Error(MessageManager.getString("error.implementation_error_multiple_single_sequence_prediction_jobs_not_supported"));
       }
 
       String altitle = getPredictionName(WebServiceName) + " for "
@@ -284,7 +284,7 @@ public class JPredClient extends WS1Client
   private WebserviceInfo setWebService()
   {
     WebServiceName = "JNetWS";
-    WebServiceJobTitle = "JNet secondary structure prediction";
+    WebServiceJobTitle = MessageManager.getString("label.jnet_secondary_structure_prediction");
     WebServiceReference = "\"Cuff J. A and Barton G.J (2000) Application of "
             + "multiple sequence alignment profiles to improve protein secondary structure prediction, "
             + "Proteins 40:502-511\".";
@@ -311,12 +311,11 @@ public class JPredClient extends WS1Client
     } catch (Exception ex)
     {
       JOptionPane.showMessageDialog(Desktop.desktop,
-              "The Secondary Structure Prediction Service named "
-                      + WebServiceName + " at " + WsURL
-                      + " couldn't be located.", "Internal Jalview Error",
+                 MessageManager.formatMessage("label.secondary_structure_prediction_service_couldnt_be_located", new String[]{WebServiceName,WsURL}),
+                 MessageManager.getString("label.internal_jalview_error"),
               JOptionPane.WARNING_MESSAGE);
-      wsInfo.setProgressText("Serious! " + WebServiceName
-              + " Service location failed\nfor URL :" + WsURL + "\n"
+      wsInfo.setProgressText(MessageManager.formatMessage("label.secondary_structure_prediction_service_couldnt_be_located", new String[]{WebServiceName,WsURL})
+                 + "\n"
               + ex.getMessage());
       wsInfo.setStatus(WebserviceInfo.STATE_STOPPED_SERVERERROR);
 
index 6531bbf..85969fc 100644 (file)
@@ -140,8 +140,7 @@ class JPredThread extends JWS1Thread implements WSClientI
             if (!jalview.analysis.SeqsetUtils.deuniquify(
                     (Hashtable) SequenceInfo, sqs))
             {
-              throw (new Exception(
-                      "Couldn't recover sequence properties for alignment."));
+              throw (new Exception(MessageManager.getString("exception.couldnt_recover_sequence_properties_for_alignment")));
             }
           }
           FirstSeq = 0;
@@ -153,8 +152,7 @@ class JPredThread extends JWS1Thread implements WSClientI
         }
         else
         {
-          throw (new Exception("Unknown format " + format
-                  + " for file : \n" + result.getAligfile()));
+          throw (new Exception(MessageManager.formatMessage("exception.unknown_format_for_file", new String[]{format,result.getAligfile()})));
         }
       }
       else
@@ -168,14 +166,13 @@ class JPredThread extends JWS1Thread implements WSClientI
                   .getAlignmentAndColumnSelection(gc))[0];
           if (this.msaIndex >= sqs.length)
           {
-            throw new Error(
-                    "Implementation Error! Invalid msaIndex for JPredJob on parent MSA input object!");
+            throw new Error(MessageManager.getString("error.implementation_error_invalid_msa_index_for_job"));
           }
 
           // ///
           // Uses RemoveGapsCommand
           // ///
-          new jalview.commands.RemoveGapsCommand("Remove Gaps",
+          new jalview.commands.RemoveGapsCommand(MessageManager.getString("label.remove_gaps"),
                   new SequenceI[]
                   { sqs[msaIndex] }, currentView);
 
@@ -186,8 +183,7 @@ class JPredThread extends JWS1Thread implements WSClientI
         if (!jalview.analysis.SeqsetUtils.SeqCharacterUnhash(
                 al.getSequenceAt(FirstSeq), SequenceInfo))
         {
-          throw (new Exception(
-                  "Couldn't recover sequence properties for JNet Query sequence!"));
+          throw (new Exception(MessageManager.getString("exception.couldnt_recover_sequence_props_for_jnet_query")));
         }
         else
         {
@@ -357,9 +353,7 @@ class JPredThread extends JWS1Thread implements WSClientI
   {
     if (!(j instanceof JPredJob))
     {
-      throw new Error(
-              "Implementation error - StartJob(JpredJob) called on "
-                      + j.getClass());
+      throw new Error(MessageManager.formatMessage("error.implementation_error_startjob_called", new String[]{j.getClass().toString()}));
     }
     try
     {
@@ -380,7 +374,7 @@ class JPredThread extends JWS1Thread implements WSClientI
         {
           job.result = (vamsas.objects.simple.Result) new JpredResult();
           job.result.setInvalid(true);
-          job.result.setStatus("Submission " + job.getJobId());
+          job.result.setStatus(MessageManager.formatMessage("label.submission_params", new String[]{job.getJobId().toString()}));
           throw new Exception(job.getJobId());
         }
         else
@@ -392,7 +386,7 @@ class JPredThread extends JWS1Thread implements WSClientI
       }
       else
       {
-        throw new Exception("Server timed out - try again later\n");
+        throw new Exception(MessageManager.getString("exception.server_timeout_try_later"));
       }
     } catch (Exception e)
     {
@@ -416,9 +410,7 @@ class JPredThread extends JWS1Thread implements WSClientI
       {
         wsInfo.setStatus(j.getJobnum(), WebserviceInfo.STATE_STOPPED_ERROR);
         // JBPNote - this could be a popup informing the user of the problem.
-        wsInfo.appendProgressText(j.getJobnum(),
-                "Failed to submit the prediction:\n" + e.getMessage()
-                        + wsInfo.getProgressText());
+        wsInfo.appendProgressText(j.getJobnum(), MessageManager.formatMessage("info.failed_to_submit_prediction", new String[]{e.getMessage(),wsInfo.getProgressText()}));
 
         jalview.bin.Cache.log.debug(
                 "Failed Submission of job " + j.getJobnum(), e);
@@ -508,8 +500,7 @@ class JPredThread extends JWS1Thread implements WSClientI
             else
             {
               // do merge with other job results
-              throw new Error(
-                      "Multiple JNet subjob merging not yet implemented.");
+              throw new Error(MessageManager.getString("error.multiple_jnet_subjob_merge_not_implemented"));
             }
           } catch (Exception e)
           {
@@ -517,9 +508,7 @@ class JPredThread extends JWS1Thread implements WSClientI
                     "JNet Client: JPred Annotation Parse Error", e);
             wsInfo.setStatus(j.getJobnum(),
                     WebserviceInfo.STATE_STOPPED_ERROR);
-            wsInfo.appendProgressText(j.getJobnum(), OutputHeader + "\n"
-                    + j.result.getStatus()
-                    + "\nInvalid JNet job result data!\n" + e.getMessage());
+            wsInfo.appendProgressText(j.getJobnum(), MessageManager.formatMessage("info.invalid_jnet_job_result_data", new String[]{OutputHeader.toString(),j.result.getStatus(), e.getMessage() }));
             j.result.setBroken(true);
           }
         }
@@ -587,7 +576,7 @@ class JPredThread extends JWS1Thread implements WSClientI
 
   public void cancelJob()
   {
-    throw new Error("Implementation error!");
+    throw new Error(MessageManager.getString("error.implementation_error"));
   }
 
   public boolean canMergeResults()
index 7285639..5d84286 100644 (file)
@@ -28,6 +28,7 @@ import javax.swing.*;
 import ext.vamsas.*;
 import jalview.datamodel.*;
 import jalview.gui.*;
+import jalview.util.MessageManager;
 
 /**
  * DOCUMENT ME!
@@ -72,10 +73,8 @@ public class MsaWSClient extends WS1Client
       JOptionPane
               .showMessageDialog(
                       Desktop.desktop,
-                      "The Service called \n"
-                              + sh.getName()
-                              + "\nis not a \nMultiple Sequence Alignment Service !",
-                      "Internal Jalview Error", JOptionPane.WARNING_MESSAGE);
+                      MessageManager.formatMessage("label.service_called_is_not_msa_service", new String[]{sh.getName()}),
+                      MessageManager.getString("label.internal_jalview_error"), JOptionPane.WARNING_MESSAGE);
 
       return;
     }
@@ -84,9 +83,8 @@ public class MsaWSClient extends WS1Client
     {
       JOptionPane.showMessageDialog(
               Desktop.desktop,
-              "The Multiple Sequence Alignment Service named "
-                      + sh.getName() + " is unknown",
-              "Internal Jalview Error", JOptionPane.WARNING_MESSAGE);
+              MessageManager.formatMessage("label.msa_service_is_unknown", new String[]{sh.getName()}),
+              MessageManager.getString("label.internal_jalview_error"), JOptionPane.WARNING_MESSAGE);
 
       return;
     }
index 2d111ca..a6ba751 100644 (file)
@@ -26,6 +26,7 @@ import jalview.analysis.*;
 import jalview.bin.*;
 import jalview.datamodel.*;
 import jalview.gui.*;
+import jalview.util.MessageManager;
 import jalview.ws.AWsJob;
 import jalview.ws.JobStateSummary;
 import jalview.ws.WSClientI;
@@ -63,7 +64,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
         subjobComplete = true;
         result = new MsaResult();
         result.setFinished(true);
-        result.setStatus("Job never ran - input returned to user.");
+        result.setStatus(MessageManager.getString("label.job_never_ran"));
       }
 
     }
@@ -86,8 +87,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
       int nseqs = 0;
       if (minlen < 0)
       {
-        throw new Error(
-                "Implementation error: minlen must be zero or more.");
+        throw new Error(MessageManager.getString("error.implementation_error_minlen_must_be_greater_zero"));
       }
       for (int i = 0; i < seqs.length; i++)
       {
@@ -431,8 +431,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
   {
     if (!(job instanceof MsaWSJob))
     {
-      throw new Error("StartJob(MsaWSJob) called on a WSJobInstance "
-              + job.getClass());
+      throw new Error(MessageManager.formatMessage("error.implementation_error_msawbjob_called", new String[]{job.getClass().toString()}));
     }
     MsaWSJob j = (MsaWSJob) job;
     if (j.isSubmitted())
@@ -450,7 +449,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
       j.setSubmitted(true);
       j.result = new MsaResult();
       j.result.setFinished(true);
-      j.result.setStatus("Empty Alignment Job");
+      j.result.setStatus(MessageManager.getString("label.empty_alignment_job"));
       ((MsaResult) j.result).setMsa(null);
     }
     try
@@ -468,10 +467,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
       {
         if (jobsubmit == null)
         {
-          throw new Exception(
-                  "Server at "
-                          + WsUrl
-                          + " returned null object, it probably cannot be contacted. Try again later ?");
+          throw new Exception(MessageManager.formatMessage("exception.web_service_returned_null_try_later", new String[]{WsUrl}));
         }
 
         throw new Exception(jobsubmit.getJobId());
@@ -491,9 +487,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
               WebserviceInfo.STATE_STOPPED_SERVERERROR);
       wsInfo.appendProgressText(
               j.getJobnum(),
-              "Failed to submit sequences for alignment.\n"
-                      + "It is most likely that there is a problem with the server.\n"
-                      + "Just close the window\n");
+              MessageManager.getString("info.failed_to_submit_sequences_for_alignment"));
 
       // e.printStackTrace(); // TODO: JBPNote DEBUG
     }
@@ -539,7 +533,7 @@ class MsaWSThread extends JWS1Thread implements WSClientI
           if (valign != null)
           {
             wsInfo.appendProgressText(jobs[j].getJobnum(),
-                    "\nAlignment Object Method Notes\n");
+                    MessageManager.getString("info.alignment_object_method_notes"));
             String[] lines = valign.getMethod();
             for (int line = 0; line < lines.length; line++)
             {
index c2e23db..c1935b4 100644 (file)
@@ -33,6 +33,7 @@ import javax.swing.*;
 import ext.vamsas.*;
 import jalview.datamodel.*;
 import jalview.gui.*;
+import jalview.util.MessageManager;
 
 /**
  * DOCUMENT ME!
@@ -76,9 +77,8 @@ public class SeqSearchWSClient extends WS1Client
     if (!sh.getAbstractName().equals(this.getServiceActionKey()))
     {
       JOptionPane.showMessageDialog(Desktop.desktop,
-              "The Service called \n" + sh.getName()
-                      + "\nis not a \nSequence Search Service !",
-              "Internal Jalview Error", JOptionPane.WARNING_MESSAGE);
+                 MessageManager.formatMessage("label.service_called_is_not_seq_search_service", new String[]{sh.getName()}),
+              MessageManager.getString("label.internal_jalview_error"), JOptionPane.WARNING_MESSAGE);
 
       return;
     }
@@ -86,8 +86,8 @@ public class SeqSearchWSClient extends WS1Client
     if ((wsInfo = setWebService(sh)) == null)
     {
       JOptionPane.showMessageDialog(Desktop.desktop,
-              "The Sequence Search Service named " + sh.getName()
-                      + " is unknown", "Internal Jalview Error",
+                 MessageManager.formatMessage("label.seq_search_service_is_unknown", new String[]{sh.getName()}),
+              MessageManager.getString("label.internal_jalview_error"),
               JOptionPane.WARNING_MESSAGE);
 
       return;
@@ -208,7 +208,7 @@ public class SeqSearchWSClient extends WS1Client
     }
     if (!locateWebService())
     {
-      throw new Exception("Cannot contact service endpoint at " + WsURL);
+      throw new Exception(MessageManager.formatMessage("exception.cannot_contact_service_endpoint_at", new String[]{WsURL}));
     }
     String database = server.getDatabase();
     if (database == null)
index b9d38fe..7c2ea49 100644 (file)
@@ -27,6 +27,7 @@ import jalview.bin.*;
 import jalview.datamodel.*;
 import jalview.gui.*;
 import jalview.io.NewickFile;
+import jalview.util.MessageManager;
 import jalview.ws.AWsJob;
 import jalview.ws.JobStateSummary;
 import jalview.ws.WSClientI;
@@ -61,7 +62,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
         subjobComplete = true;
         result = new MsaResult();
         result.setFinished(true);
-        result.setStatus("Job never ran - input returned to user.");
+        result.setStatus(MessageManager.getString("label.job_never_ran"));
       }
 
     }
@@ -84,8 +85,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
       int nseqs = 0;
       if (minlen < 0)
       {
-        throw new Error(
-                "Implementation error: minlen must be zero or more.");
+          throw new Error(MessageManager.getString("error.implementation_error_minlen_must_be_greater_zero"));
       }
       for (int i = 0; i < seqs.length; i++)
       {
@@ -446,8 +446,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
   {
     if (!(job instanceof SeqSearchWSJob))
     {
-      throw new Error("StartJob(MsaWSJob) called on a WSJobInstance "
-              + job.getClass());
+        throw new Error(MessageManager.formatMessage("error.implementation_error_msawbjob_called", new String[]{job.getClass().toString()}));
     }
     SeqSearchWSJob j = (SeqSearchWSJob) job;
     if (j.isSubmitted())
@@ -465,7 +464,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
       j.setSubmitted(true);
       j.result = new MsaResult();
       j.result.setFinished(true);
-      j.result.setStatus("Empty Alignment Job");
+      j.result.setStatus(MessageManager.getString("label.empty_alignment_job"));
       ((MsaResult) j.result).setMsa(null);
     }
     try
@@ -484,10 +483,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
       {
         if (jobsubmit == null)
         {
-          throw new Exception(
-                  "Server at "
-                          + WsUrl
-                          + " returned null object, it probably cannot be contacted. Try again later ?");
+          throw new Exception(MessageManager.formatMessage("exception.web_service_returned_null_try_later", new String[]{WsUrl}));
         }
 
         throw new Exception(jobsubmit.getJobId());
@@ -507,9 +503,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
               WebserviceInfo.STATE_STOPPED_SERVERERROR);
       wsInfo.appendProgressText(
               j.getJobnum(),
-              "Failed to submit sequences for alignment.\n"
-                      + "It is most likely that there is a problem with the server.\n"
-                      + "Just close the window\n");
+              MessageManager.getString("info.failed_to_submit_sequences_for_alignment"));
 
       // e.printStackTrace(); // TODO: JBPNote DEBUG
     }
@@ -548,7 +542,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
           if (valign != null)
           {
             wsInfo.appendProgressText(jobs[j].getJobnum(),
-                    "\nAlignment Object Method Notes\n");
+                    MessageManager.getString("info.alignment_object_method_notes"));
             String[] lines = valign.getMethod();
             for (int line = 0; line < lines.length; line++)
             {
@@ -648,7 +642,7 @@ class SeqSearchWSThread extends JWS1Thread implements WSClientI
               AlignFrame.DEFAULT_WIDTH, AlignFrame.DEFAULT_HEIGHT);
       if (nf != null)
       {
-        af.ShowNewickTree(nf, "Tree from " + this.alTitle);
+        af.ShowNewickTree(nf, MessageManager.formatMessage("label.tree_from", new String[]{this.alTitle}));
       }
       // initialise with same renderer settings as in parent alignframe.
       af.getFeatureRenderer().transferSettings(this.featureSettings);
index 4d1af4c..210e520 100644 (file)
@@ -22,6 +22,7 @@ package jalview.ws.jws1;
 
 import jalview.gui.AlignFrame;
 import jalview.gui.WebserviceInfo;
+import jalview.util.MessageManager;
 import jalview.ws.WSClient;
 import jalview.ws.WSMenuEntryProviderI;
 
@@ -109,8 +110,7 @@ public abstract class WS1Client extends WSClient implements
   {
     if (serviceHandle == null)
     {
-      throw new Error(
-              "IMPLEMENTATION ERROR: cannot attach WS Menu Entry without service handle reference!");
+      throw new Error(MessageManager.getString("error.implementation_error_cannot_attach_ws_menu_entry"));
     }
     attachWSMenuEntry(wsmenu, serviceHandle, alignFrame);
   }
index 65f939a..7c0eabd 100644 (file)
@@ -35,6 +35,7 @@ import compbio.metadata.Preset;
 import compbio.metadata.PresetManager;
 import compbio.metadata.RunnerConfig;
 
+import jalview.util.MessageManager;
 import jalview.ws.jws2.dm.JabaOption;
 import jalview.ws.jws2.dm.JabaParameter;
 import jalview.ws.jws2.dm.JabaWsParamSet;
@@ -166,9 +167,7 @@ public class JabaParamStore implements ParamDatastoreI
       }
       if (narg == null)
       {
-        throw new Error(
-                "Implementation Error: Cannot handle Jaba parameter object "
-                        + rg.getClass());
+        throw new Error(MessageManager.formatMessage("error.implementation_error_cannot_handle_jaba_param", new String[]{rg.getClass().toString()}));
       }
       else
       {
@@ -203,9 +202,7 @@ public class JabaParamStore implements ParamDatastoreI
               .getOption() : null;
       if (narg == null)
       {
-        throw new Error(
-                "Implementation Error: Cannot handle Jaba parameter object "
-                        + rg.getClass());
+          throw new Error(MessageManager.formatMessage("error.implementation_error_cannot_handle_jaba_param", new String[]{rg.getClass().toString()}));
       }
       else
       {
@@ -243,8 +240,7 @@ public class JabaParamStore implements ParamDatastoreI
     }
     if (servicePresets.containsKey(name))
     {
-      throw new Error(
-              "Implementation error: Attempt to delete a service preset!");
+      throw new Error(MessageManager.getString("error.implementation_error_attempt_to_delete_service_preset"));
     }
   }
 
@@ -270,9 +266,7 @@ public class JabaParamStore implements ParamDatastoreI
             : getPreset(presetName));
     if (jps == null)
     {
-      throw new Error("Implementation error: Can't locate either oldname ("
-              + oldName + ") or presetName (" + presetName
-              + "in the datastore!");
+      throw new Error(MessageManager.formatMessage("error.implementation_error_cannot_locate_oldname_presetname", new String[]{oldName,presetName}));
     }
     jps.setName(presetName);
     jps.setDescription(text);
@@ -322,8 +316,7 @@ public class JabaParamStore implements ParamDatastoreI
   {
     if (!involves(urls))
     {
-      throw new IOException(
-              "Implementation error: Cannot find service url in the given url set!");
+      throw new IOException(MessageManager.getString("error.implementation_error_cannot_find_service_url_in_given_set"));
 
     }
     JabaWsParamSet wsp = new JabaWsParamSet();
@@ -348,15 +341,11 @@ public class JabaParamStore implements ParamDatastoreI
   {
     if (!involves(pset.getApplicableUrls()))
     {
-      throw new IOException(
-              "Implementation error: Cannot find service url in the given url set for this service parameter store ("
-                      + service.getUri() + ") !");
-
+      throw new IOException(MessageManager.formatMessage("error.implementation_error_cannot_find_service_url_in_given_set_param_store", new String[]{service.getUri()}));
     }
     if (!(pset instanceof JabaWsParamSet))
     {
-      throw new Error(
-              "Implementation error: JabaWsParamSets can only be handled by JabaParamStore");
+      throw new Error(MessageManager.getString("error.implementation_error_jabaws_param_set_only_handled_by"));
     }
 
     StringBuffer rslt = new StringBuffer();
index 7d7f4f0..c47c63a 100644 (file)
@@ -20,6 +20,7 @@
  */
 package jalview.ws.jws2;
 
+import jalview.util.MessageManager;
 import jalview.ws.jws2.jabaws2.Jws2Instance;
 import jalview.ws.params.ArgumentI;
 import jalview.ws.params.WsParamSetI;
@@ -74,7 +75,7 @@ public class JabaPreset implements WsParamSetI
   @Override
   public void setSourceFile(String newfile)
   {
-    throw new Error("Cannot set source file for " + getClass());
+    throw new Error(MessageManager.formatMessage("error.cannot_set_source_file_for", new String[]{getClass().toString()}));
   }
 
   @Override
@@ -87,14 +88,13 @@ public class JabaPreset implements WsParamSetI
     } catch (Exception e)
     {
       e.printStackTrace();
-      throw new Error(
-              "Probable mismatch between service instance and preset!");
+      throw new Error(MessageManager.getString("error.mismatch_service_instance_preset"));
     }
   }
 
   @Override
   public void setArguments(List<ArgumentI> args)
   {
-    throw new Error("Cannot set Parameters for a Jaba Web service's preset");
+    throw new Error(MessageManager.getString("error.cannot_set_params_for_ws_preset"));
   }
 }
index afb46e9..e966886 100644 (file)
@@ -24,6 +24,7 @@ import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.Annotation;
 import jalview.datamodel.SequenceI;
 import jalview.gui.AlignFrame;
+import jalview.util.MessageManager;
 import jalview.ws.jws2.jabaws2.Jws2Instance;
 import jalview.ws.params.WsParamSetI;
 
@@ -114,8 +115,7 @@ public abstract class JabawsCalcWorker extends AbstractJabaCalcWorker
         rslt = aaservice.customAnalize(seqs, getJabaArguments());
       } catch (WrongParameterException x)
       {
-        throw new JobSubmissionException(
-                "Invalid parameter set. Check Jalview implementation.", x);
+        throw new JobSubmissionException(MessageManager.getString("exception.jobsubmission_invalid_params_set"), x);
 
       }
     }
index 1f0d92c..3f0e47d 100644 (file)
@@ -40,6 +40,7 @@ import jalview.datamodel.AlignmentAnnotation;
 import jalview.datamodel.Annotation;
 import jalview.datamodel.SequenceI;
 import jalview.gui.AlignFrame;
+import jalview.util.MessageManager;
 import jalview.workers.AlignCalcWorker;
 import jalview.ws.jws2.jabaws2.Jws2Instance;
 import jalview.ws.params.WsParamSetI;
@@ -129,9 +130,7 @@ public abstract class JabawsMsaInterfaceAlignCalcWorker extends AbstractJabaCalc
         rslt = msaservice.customAlign(seqs, getJabaArguments());
       } catch (WrongParameterException x)
       {
-        throw new JobSubmissionException(
-                "Invalid parameter set. Check Jalview implementation.", x);
-
+          throw new JobSubmissionException(MessageManager.getString("exception.jobsubmission_invalid_params_set"), x);
       }
     }
     return rslt;
index b2b676f..afefe65 100644 (file)
@@ -77,8 +77,7 @@ public abstract class Jws2Client extends jalview.ws.WSClient
          * arguments. for (Argument opt : arguments) { newargs.add(opt); } }
          * paramset = newargs; } else {
          */
-        throw new Error(
-                "Implementation error: Can only instantiate Jaba parameter sets.");
+        throw new Error(MessageManager.getString("error.implementation_error_can_only_instantiate_jaba_param_sets"));
       }
     }
     else
@@ -231,9 +230,7 @@ public abstract class Jws2Client extends jalview.ws.WSClient
       final JCheckBoxMenuItem aaConEnabled = new JCheckBoxMenuItem(
               aaui.getAAconToggle());
 
-      aaConEnabled.setToolTipText("<html><p>"
-              + JvSwingUtils.wrapTooltip(aaui.getAAconToggleTooltip()
-                      + "</p>") + "</html>");
+      aaConEnabled.setToolTipText(JvSwingUtils.wrapTooltip(true, aaui.getAAconToggleTooltip()));
       aaConEnabled.addActionListener(new ActionListener()
       {
         @Override
@@ -257,7 +254,7 @@ public abstract class Jws2Client extends jalview.ws.WSClient
       wsmenu.add(aaConEnabled);
       final JMenuItem modifyParams = new JMenuItem(aaui.getAAeditSettings());
       modifyParams.setToolTipText("<html><p>"
-              + JvSwingUtils.wrapTooltip(aaui.getAAeditSettingsTooltip()
+              + JvSwingUtils.wrapTooltip(false, aaui.getAAeditSettingsTooltip()
                       + "</p>") + "</html>");
       modifyParams.addActionListener(new ActionListener()
       {
@@ -410,7 +407,7 @@ public abstract class Jws2Client extends jalview.ws.WSClient
     {
       // TODO raise dialog box explaining error, and/or open the JABA
       // preferences menu.
-      throw new Error("No AACon service found.");
+      throw new Error(MessageManager.getString("error.no_aacon_service_found"));
     }
     return new AAConSettings(true, service, null, null);
   }
index 144a860..910b749 100644 (file)
@@ -24,6 +24,7 @@ import jalview.bin.Cache;
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
 import jalview.gui.JvSwingUtils;
+import jalview.util.MessageManager;
 import jalview.ws.WSMenuEntryProviderI;
 import jalview.ws.jws2.jabaws2.Jws2Instance;
 import jalview.ws.params.ParamDatastoreI;
@@ -387,14 +388,14 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
         }
       });
       hitm.setToolTipText(JvSwingUtils
-              .wrapTooltip("Opens the JABAWS server's homepage in web browser"));
+              .wrapTooltip(false, MessageManager.getString("label.open_jabaws_web_page ")));
 
       service.attachWSMenuEntry(atpoint, alignFrame);
       if (alternates.containsKey(service.serviceType))
       {
-        atpoint.add(hitm = new JMenu("Switch server"));
+        atpoint.add(hitm = new JMenu(MessageManager.getString("label.switch_server")));
         hitm.setToolTipText(JvSwingUtils
-                .wrapTooltip("Choose a server for running this service"));
+                .wrapTooltip(false, MessageManager.getString("label.choose_jabaws_server")));
         for (final Jws2Instance sv : alternates.get(service.serviceType))
         {
           JMenuItem itm;
@@ -483,7 +484,7 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
           atpoint = JvSwingUtils.findOrCreateMenu(atpoint, host);
           if (atpoint.getToolTipText() == null)
           {
-            atpoint.setToolTipText("Services at " + host);
+            atpoint.setToolTipText(MessageManager.formatMessage("label.services_at", new String[]{host}));
           }
         }
         if (bytype)
@@ -528,7 +529,7 @@ public class Jws2Discoverer implements Runnable, WSMenuEntryProviderI
               }
             });
             hitm.setToolTipText(JvSwingUtils
-                    .wrapTooltip("Opens the JABAWS server's homepage in web browser"));
+                    .wrapTooltip(true, MessageManager.getString("label.open_jabaws_web_page")));
             lasthostFor.put(service.action, host);
           }
           hostLabels.add(host + service.serviceType
index 285dcc0..9ddc69a 100644 (file)
@@ -101,10 +101,8 @@ public class MsaWSClient extends Jws2Client
       JOptionPane
               .showMessageDialog(
                       Desktop.desktop,
-                      "The Service called \n"
-                              + sh.serviceType
-                              + "\nis not a \nMultiple Sequence Alignment Service !",
-                      "Internal Jalview Error", JOptionPane.WARNING_MESSAGE);
+                      MessageManager.formatMessage("label.service_called_is_not_msa_service", new String[]{sh.serviceType}),
+                      MessageManager.getString("label.internal_jalview_error"), JOptionPane.WARNING_MESSAGE);
 
       return;
     }
@@ -112,9 +110,8 @@ public class MsaWSClient extends Jws2Client
     if ((wsInfo = setWebService(sh, false)) == null)
     {
       JOptionPane.showMessageDialog(Desktop.desktop,
-              "The Multiple Sequence Alignment Service named "
-                      + sh.serviceType + " is unknown",
-              "Internal Jalview Error", JOptionPane.WARNING_MESSAGE);
+                 MessageManager.formatMessage("label.msa_service_is_unknown", new String[]{sh.serviceType}),
+                 MessageManager.getString("label.internal_jalview_error"), JOptionPane.WARNING_MESSAGE);
 
       return;
     }
@@ -279,11 +276,10 @@ public class MsaWSClient extends Jws2Client
           for (final WsParamSetI preset : presets)
           {
             final JMenuItem methodR = new JMenuItem(preset.getName());
-            methodR.setToolTipText("<html><p>"
-                    + JvSwingUtils.wrapTooltip("<strong>"
-                            + (preset.isModifiable() ? "User Preset"
-                                    : "Service Preset") + "</strong><br/>"
-                            + preset.getDescription() + "</p>") + "</html>");
+            methodR.setToolTipText(JvSwingUtils.wrapTooltip(true, "<p><strong>"
+                            + (preset.isModifiable() ? MessageManager.getString("label.user_preset")
+                                    : MessageManager.getString("label.service_preset")) + "</strong><br/>"
+                            + preset.getDescription() + "</p>"));
             methodR.addActionListener(new ActionListener()
             {
               public void actionPerformed(ActionEvent e)
index f40c250..5e8cb98 100644 (file)
@@ -32,6 +32,7 @@ import jalview.analysis.*;
 import jalview.bin.*;
 import jalview.datamodel.*;
 import jalview.gui.*;
+import jalview.util.MessageManager;
 import jalview.ws.AWsJob;
 import jalview.ws.WSClientI;
 import jalview.ws.JobStateSummary;
@@ -109,8 +110,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
       int nseqs = 0;
       if (minlen < 0)
       {
-        throw new Error(
-                "Implementation error: minlen must be zero or more.");
+        throw new Error(MessageManager.getString("error.implementation_error_minlen_must_be_greater_zero"));
       }
       for (int i = 0; i < seqs.length; i++)
       {
@@ -625,8 +625,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
     // boiler plate template
     if (!(job instanceof MsaWSJob))
     {
-      throw new Error("StartJob(MsaWSJob) called on a WSJobInstance "
-              + job.getClass());
+      throw new Error(MessageManager.formatMessage("error.implementation_error_msawbjob_called", new String[]{job.getClass().toString()}));
     }
     MsaWSJob j = (MsaWSJob) job;
     if (j.isSubmitted())
@@ -644,7 +643,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
     {
       // special case - selection consisted entirely of empty sequences...
       j.setjobStatus(JobStatus.FINISHED);
-      j.setStatus("Empty Alignment Job");
+      j.setStatus(MessageManager.getString("label.empty_alignment_job"));
     }
     try
     {
@@ -672,35 +671,28 @@ class MsaWSThread extends AWS2Thread implements WSClientI
       }
       else
       {
-        throw new Exception(
-                "Server at "
-                        + WsUrl
-                        + " returned null string for job id, it probably cannot be contacted. Try again later ?");
+        throw new Exception(MessageManager.formatMessage("exception.web_service_returned_null_try_later", new String[]{WsUrl}));
       }
     } catch (compbio.metadata.UnsupportedRuntimeException _lex)
     {
       lex = _lex;
-      wsInfo.appendProgressText("Job could not be run because the server doesn't support this program.\n"
-              + _lex.getMessage());
-      wsInfo.warnUser(_lex.getMessage(), "Service not supported!");
+      wsInfo.appendProgressText(MessageManager.formatMessage("info.job_couldnt_be_run_server_doesnt_support_program", new String[]{_lex.getMessage()}));
+      wsInfo.warnUser(_lex.getMessage(), MessageManager.getString("warn.service_not_supported"));
       wsInfo.setStatus(WebserviceInfo.STATE_STOPPED_SERVERERROR);
       wsInfo.setStatus(j.getJobnum(),
               WebserviceInfo.STATE_STOPPED_SERVERERROR);
     } catch (compbio.metadata.LimitExceededException _lex)
     {
       lex = _lex;
-      wsInfo.appendProgressText("Job could not be run because it exceeded a hard limit on the server.\n"
-              + _lex.getMessage());
-      wsInfo.warnUser(_lex.getMessage(), "Input is too big!");
+      wsInfo.appendProgressText(MessageManager.formatMessage("info.job_couldnt_be_run_exceeded_hard_limit", new String[]{_lex.getMessage()}));
+      wsInfo.warnUser(_lex.getMessage(), MessageManager.getString("warn.input_is_too_big"));
       wsInfo.setStatus(WebserviceInfo.STATE_STOPPED_ERROR);
       wsInfo.setStatus(j.getJobnum(), WebserviceInfo.STATE_STOPPED_ERROR);
     } catch (compbio.metadata.WrongParameterException _lex)
     {
       lex = _lex;
-      wsInfo.warnUser(_lex.getMessage(), "Invalid job parameter set!");
-      wsInfo.appendProgressText("Job could not be run because some of the parameter settings are not supported by the server.\n"
-              + _lex.getMessage()
-              + "\nPlease check to make sure you have used the correct parameter set for this service!\n");
+      wsInfo.warnUser(_lex.getMessage(), MessageManager.getString("warn.invalid_job_param_set"));
+      wsInfo.appendProgressText(MessageManager.formatMessage("info.job_couldnt_be_run_incorrect_param_setting", new String[]{_lex.getMessage()}));
       wsInfo.setStatus(WebserviceInfo.STATE_STOPPED_ERROR);
       wsInfo.setStatus(j.getJobnum(), WebserviceInfo.STATE_STOPPED_ERROR);
     } catch (Error e)
@@ -734,8 +726,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
 
         j.setAllowedServerExceptions(0);
         wsInfo.appendProgressText(j.getJobnum(),
-                "Failed to submit sequences for alignment.\n"
-                        + "Just close the window\n");
+                MessageManager.getString("info.failed_to_submit_sequences_for_alignment"));
       }
     }
   }
@@ -743,7 +734,7 @@ class MsaWSThread extends AWS2Thread implements WSClientI
   public void parseResult()
   {
     long progbar = System.currentTimeMillis();
-    wsInfo.setProgressBar("Collecting job results.", progbar);
+    wsInfo.setProgressBar(MessageManager.getString("status.collecting_job_results"), progbar);
     int results = 0; // number of result sets received
     JobStateSummary finalState = new JobStateSummary();
     try
index e2bfbbd..8916be9 100644 (file)
@@ -20,6 +20,8 @@
  */
 package jalview.ws.jws2;
 
+import jalview.util.MessageManager;
+
 import java.net.MalformedURLException;
 import java.util.ArrayList;
 import java.util.HashSet;
@@ -181,8 +183,7 @@ public class ParameterUtils
     } catch (Exception e)
     {
       e.printStackTrace();
-      throw new Error(
-              "Implementation error: could not copy ValueConstrain!");
+      throw new Error(MessageManager.getString("error.implementation_error_couldnt_copy_value_constraint"));
     }
   }
 
index 13568ea..3976678 100644 (file)
@@ -106,7 +106,7 @@ public class SequenceAnnotationWSClient extends Jws2Client
         } catch (Exception x)
         {
           x.printStackTrace();
-          throw new Error("Implementation error", x);
+          throw new Error(MessageManager.getString("error.implementation_error"), x);
         }
         alignFrame.getViewport().getCalcManager().registerWorker(worker);
         alignFrame.getViewport().getCalcManager().startWorker(worker);
@@ -209,16 +209,15 @@ public class SequenceAnnotationWSClient extends Jws2Client
       List<WsParamSetI> presets = service.getParamStore().getPresets();
       if (presets != null && presets.size() > 0)
       {
-        JMenu presetlist = new JMenu("Run " + calcName + "with preset");
+        JMenu presetlist = new JMenu(MessageManager.formatMessage("label.run_with_preset", new String[]{calcName}));
 
         for (final WsParamSetI preset : presets)
         {
           final JMenuItem methodR = new JMenuItem(preset.getName());
-          methodR.setToolTipText("<html><p>"
-                  + JvSwingUtils.wrapTooltip("<strong>"
-                          + (preset.isModifiable() ? "User Preset"
-                                  : "Service Preset") + "</strong><br/>"
-                          + preset.getDescription() + "</p>") + "</html>");
+          methodR.setToolTipText(JvSwingUtils.wrapTooltip(true, "<strong>"
+                          + (preset.isModifiable() ? MessageManager.getString("label.user_preset")
+                                  : MessageManager.getString("label.service_preset")) + "</strong><br/>"
+                          + preset.getDescription()));
           methodR.addActionListener(new ActionListener()
           {
             public void actionPerformed(ActionEvent e)
@@ -249,10 +248,7 @@ public class SequenceAnnotationWSClient extends Jws2Client
             Desktop.instance.showUrl(service.docUrl);
           }
         });
-        annotservice.setToolTipText("<html>"
-                + JvSwingUtils.wrapTooltip("View <a href=\""
-                        + service.docUrl + "\">" + service.docUrl + "</a>")
-                + "</html>");
+        annotservice.setToolTipText(JvSwingUtils.wrapTooltip(true, MessageManager.formatMessage("label.view_service_doc_url", new String[]{service.docUrl,service.docUrl})));
         wsmenu.add(annotservice);
       }
     }
index 28a6955..e78172e 100644 (file)
@@ -26,6 +26,7 @@ import java.util.List;
 import compbio.metadata.Argument;
 import compbio.metadata.Option;
 
+import jalview.util.MessageManager;
 import jalview.ws.jws2.JabaParamStore;
 import jalview.ws.jws2.JabaPreset;
 import jalview.ws.jws2.ParameterUtils;
@@ -92,7 +93,7 @@ public class AAConSettings extends jalview.ws.params.AutoCalcSetting
         return;
       }
       // Try even harder to migrate arguments.
-      throw new Error("Parameter migration not implemented yet");
+      throw new Error(MessageManager.getString("error.parameter_migration_not_implemented_yet"));
     }
   }
 
index f29b6ed..995af35 100644 (file)
@@ -20,6 +20,7 @@
  */
 package jalview.ws.jws2.dm;
 
+import jalview.util.MessageManager;
 import jalview.ws.jws2.ParameterUtils;
 import jalview.ws.params.OptionI;
 
@@ -94,8 +95,7 @@ public class JabaOption implements jalview.ws.params.OptionI
     } catch (Exception e)
     {
       e.printStackTrace();
-      throw new Error(
-              "Implementation error: cannot set Jaba Option to a value outside its allowed value range!");
+      throw new Error(MessageManager.getString("error.implementation_error_cannot_set_jaba_option"));
     }
   }
 
index f57abde..920b73e 100644 (file)
@@ -22,6 +22,7 @@ package jalview.ws.jws2.dm;
 
 import compbio.metadata.ValueConstrain;
 
+import jalview.util.MessageManager;
 import jalview.ws.params.ValueConstrainI;
 
 public class JabaValueConstrain implements ValueConstrainI
@@ -45,9 +46,7 @@ public class JabaValueConstrain implements ValueConstrainI
     {
       return ValueType.Integer;
     }
-    throw new Error(
-            "IMPLEMENTATION ERROR: jalview.ws.params.ValueConstrainI.ValueType does not support the JABAWS type :"
-                    + vc.toString());
+    throw new Error(MessageManager.formatMessage("error.implementation_error_valuetype_doesnt_support_jabaws_type", new String[]{vc.toString()}));
   }
 
   @Override
index 7a67f6e..d6d1d5c 100644 (file)
@@ -25,6 +25,7 @@ import java.util.List;
 
 import compbio.metadata.Option;
 
+import jalview.util.MessageManager;
 import jalview.ws.jws2.JabaParamStore;
 import jalview.ws.params.ArgumentI;
 import jalview.ws.params.WsParamSetI;
@@ -53,8 +54,7 @@ public class JabaWsParamSet implements WsParamSetI
       {
         if (!allJaba(jobParams))
         {
-          throw new Error(
-                  "Cannot create a JabaWSParamSet from non-JabaWS parameters");
+          throw new Error(MessageManager.getString("error.cannot_create_jabaws_param_set"));
         }
         else
         {
@@ -177,8 +177,7 @@ public class JabaWsParamSet implements WsParamSetI
   {
     if (!allJaba(args))
     {
-      throw new Error(
-              "Cannot set arguments to a JabaWSParamSet that are not JabaWS arguments");
+      throw new Error(MessageManager.getString("error.cannot_set_arguments_to_jabaws_param_set"));
     }
     jabaArguments = new ArrayList<Option>();
     for (ArgumentI rg : args)
index 7e9f668..120ce27 100644 (file)
@@ -22,6 +22,7 @@ package jalview.ws.jws2.jabaws2;
 
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
+import jalview.util.MessageManager;
 import jalview.ws.jws2.JabaParamStore;
 import jalview.ws.jws2.MsaWSClient;
 import jalview.ws.jws2.SequenceAnnotationWSClient;
@@ -156,9 +157,7 @@ public class Jws2Instance
     {
       return ((SequenceAnnotation) service).getRunnerOptions();
     }
-    throw new Error(
-            "Implementation Error: Runner Config not available for a JABAWS service of type "
-                    + serviceType + " (" + service.getClass() + ")");
+    throw new Error(MessageManager.formatMessage("error.implementation_error_runner_config_not_available", new String[]{serviceType,service.getClass().toString()}));
   }
 
   @Override
index c8e6ad4..5af6b32 100644 (file)
@@ -26,6 +26,7 @@ import jalview.io.packed.DataProvider;
 import jalview.io.packed.ParsePackedSet;
 import jalview.io.packed.SimpleDataProvider;
 import jalview.io.packed.DataProvider.JvDataType;
+import jalview.util.MessageManager;
 import jalview.ws.io.mime.JalviewMimeContentHandler;
 
 import java.io.BufferedReader;
@@ -110,8 +111,7 @@ public class HttpResultSet extends FileParse
 
     if (en == null)
     {
-      throw new Error(
-              "Implementation Error: need to have an HttpResponse to process.");
+      throw new Error(MessageManager.getString("error.implementation_error_need_to_have_httpresponse"));
     }
     jalview.io.packed.JalviewDataset ds = restJob.newJalviewDataset();
     // Decide how we deal with content.
index 5f827a9..cd4bb23 100644 (file)
@@ -39,6 +39,7 @@ import jalview.gui.AlignmentPanel;
 import jalview.gui.Desktop;
 import jalview.gui.WebserviceInfo;
 import jalview.io.packed.DataProvider.JvDataType;
+import jalview.util.MessageManager;
 import jalview.ws.WSClient;
 import jalview.ws.WSClientI;
 import jalview.ws.WSMenuEntryProviderI;
@@ -96,8 +97,7 @@ public class RestClient extends WSClient implements WSClientI,
 
   public void setWebserviceInfo(boolean headless)
   {
-    WebServiceJobTitle = service.details.Action + " using "
-            + service.details.Name;
+    WebServiceJobTitle = MessageManager.formatMessage("label.webservice_job_title", new String[]{service.details.Action,service.details.Name});
     WebServiceName = service.details.Name;
     WebServiceReference = "No reference - go to url for more info";
     if (service.details.description != null)
@@ -140,8 +140,7 @@ public class RestClient extends WSClient implements WSClientI,
           final AlignFrame alignFrame)
   {
     JMenuItem submit = new JMenuItem(service.details.Name);
-    submit.setToolTipText(service.details.Action + " using "
-            + service.details.Name);
+    submit.setToolTipText(MessageManager.formatMessage("label.rest_client_submit", new String[]{service.details.Action,service.details.Name}));
     submit.addActionListener(new ActionListener()
     {
 
@@ -258,9 +257,7 @@ public class RestClient extends WSClient implements WSClientI,
           _input = new AlignmentView(av.getAlignment(),
                   av.getColumnSelection(), av.getSelectionGroup(),
                   av.hasHiddenColumns(), true, true);
-          viewTitle = "selected "
-                  + (av.hasHiddenColumns() ? "visible" : "")
-                  + " region of " + af.getTitle();
+          viewTitle = MessageManager.formatMessage("label.select_visible_region_of", new String[]{(av.hasHiddenColumns() ? MessageManager.getString("label.visible") : ""),af.getTitle()});
         }
         else
         {
@@ -269,9 +266,7 @@ public class RestClient extends WSClient implements WSClientI,
                   av.getColumnSelection(), av.getSelectionGroup(),
                   av.hasHiddenColumns(), false, true);
         }
-        viewTitle = "select and unselected "
-                + (av.hasHiddenColumns() ? "visible" : "")
-                + " regions from " + af.getTitle();
+        viewTitle = MessageManager.formatMessage("label.select_unselect_visible_regions_from", new String[]{(av.hasHiddenColumns() ? MessageManager.getString("label.visible") : ""),af.getTitle()});
       }
       else
       {
@@ -279,8 +274,7 @@ public class RestClient extends WSClient implements WSClientI,
         _input = new AlignmentView(av.getAlignment(),
                 av.getColumnSelection(), av.getSelectionGroup(),
                 av.hasHiddenColumns(), true, true);
-        viewTitle = "selected " + (av.hasHiddenColumns() ? "visible" : "")
-                + " region of " + af.getTitle();
+        viewTitle = MessageManager.formatMessage("label.select_visible_region_of", new String[]{(av.hasHiddenColumns() ? MessageManager.getString("label.visible") : ""),af.getTitle()});
       }
     }
     else
@@ -289,7 +283,7 @@ public class RestClient extends WSClient implements WSClientI,
       _input = new AlignmentView(av.getAlignment(),
               av.getColumnSelection(), null, av.hasHiddenColumns(), false,
               true);
-      viewTitle = "" + (av.hasHiddenColumns() ? "visible region of " : "")
+      viewTitle = "" + (av.hasHiddenColumns() ? (new StringBuffer(" ").append(MessageManager.getString("label.visible_region_of")).toString()) : "")
               + af.getTitle();
     }
 
@@ -312,15 +306,15 @@ public class RestClient extends WSClient implements WSClientI,
               .showMessageDialog(
                       Desktop.desktop,
                       (jobsthread.hasWarnings() ? jobsthread.getWarnings()
-                              : "The Job couldn't be started. Please check your input, and the Jalview console for any warning messages."),
-                      "Unable to start web service analysis",
+                              : MessageManager.getString("label.job_couldnt_be_started_check_input")),
+                      MessageManager.getString("label.unable_start_web_service_analysis"),
                       JOptionPane.WARNING_MESSAGE);
     }
   }
 
   public static RestClient makeShmmrRestClient()
   {
-    String action = "Analysis", description = "Sequence Harmony and Multi-Relief (Brandt et al. 2010)", name = "Multi-Harmony";
+    String action = "Analysis", description = "Sequence Harmony and Multi-Relief (Brandt et al. 2010)", name = MessageManager.getString("label.multiharmony");
     Hashtable<String, InputType> iparams = new Hashtable<String, InputType>();
     jalview.ws.rest.params.JobConstant toolp;
     // toolp = new jalview.ws.rest.JobConstant("tool","jalview");
index b529045..738d5dd 100644 (file)
@@ -36,6 +36,7 @@ import jalview.gui.WebserviceInfo;
 import jalview.io.NewickFile;
 import jalview.io.packed.JalviewDataset;
 import jalview.io.packed.JalviewDataset.AlignmentSet;
+import jalview.util.MessageManager;
 import jalview.ws.AWSThread;
 import jalview.ws.AWsJob;
 
@@ -805,7 +806,7 @@ public class RestJobThread extends AWSThread
               destAls.add(destAl);
               destColsel.add(destCs);
               resultDest.add(AddDataTo.newAlignment);
-              throw new Error("Impl. Error! TODO: ");
+              throw new Error(MessageManager.getString("error.implementation_error")+"TODO: ");
             }
           }
           /**
@@ -1041,9 +1042,7 @@ public class RestJobThread extends AWSThread
     {
       AlignmentI destal;
       ColumnSelection destcs;
-      String alTitle = restClient.service.details.Action + " using "
-              + restClient.service.details.Name + " on "
-              + restClient.viewTitle;
+      String alTitle = MessageManager.formatMessage("label.webservice_job_title_on", new String[]{restClient.service.details.Action,restClient.service.details.Name,restClient.viewTitle});
       switch (action)
       {
       case newAlignment:
index 37a223c..0bade86 100644 (file)
@@ -20,6 +20,7 @@
  */
 package jalview.ws.rest.params;
 
+import jalview.util.MessageManager;
 import jalview.ws.params.OptionI;
 import jalview.ws.rest.InputType;
 import jalview.ws.rest.NoValidInputDataException;
@@ -79,7 +80,7 @@ public class JobConstant extends InputType
         prm.add(URLEncoder.encode(value, "UTF-8"));
       } catch (UnsupportedEncodingException ex)
       {
-        throw new Error("Couldn't encode '" + value + "' as UTF-8.", ex);
+        throw new Error(MessageManager.formatMessage("error.couldnt_encode_as_utf8", new String[]{value}), ex);
 
       }
     }
index 30dc473..70686c5 100644 (file)
@@ -23,6 +23,7 @@ package jalview.ws.rest.params;
 import jalview.datamodel.AlignmentI;
 import jalview.datamodel.SequenceGroup;
 import jalview.datamodel.SequenceI;
+import jalview.util.MessageManager;
 import jalview.ws.params.OptionI;
 import jalview.ws.params.simple.IntegerParameter;
 import jalview.ws.params.simple.Option;
@@ -99,8 +100,7 @@ public class SeqGroupIndexVector extends InputType implements
       {
         if (sg.getSize() < minsize)
         {
-          throw new NoValidInputDataException("Group contains less than "
-                  + minsize + " sequences.");
+          throw new NoValidInputDataException(MessageManager.formatMessage("exception.notvaliddata_group_contains_less_than_min_seqs", new String[]{Integer.valueOf(minsize).toString()}));
         }
         // TODO: refactor to sequenceGroup for efficiency -
         // getAlignmentRowInterval(AlignmentI al)
index 7462cac..2c58ed8 100644 (file)
@@ -20,6 +20,7 @@
  */
 package jalview.ws.rest.params;
 
+import jalview.util.MessageManager;
 import jalview.ws.params.OptionI;
 import jalview.ws.rest.InputType;
 import jalview.ws.rest.RestJob;
@@ -53,7 +54,7 @@ public class Tree extends InputType
     /*
      * rj.getTreeForInput(token); return new StringBody(new )
      */
-    throw new Error("Tree InputType not yet implemented");
+    throw new Error(MessageManager.getString("error.tree_inputtype_not_yet_implemented"));
     // return null;
   }
 
index afdb516..ba7e062 100644 (file)
@@ -24,6 +24,7 @@ import jalview.datamodel.AlignmentI;
 import jalview.datamodel.DBRefEntry;
 import jalview.datamodel.SequenceI;
 import jalview.util.DBRefUtils;
+import jalview.util.MessageManager;
 
 import java.util.ArrayList;
 import java.util.Enumeration;
@@ -326,7 +327,7 @@ public class ASequenceFetcher
     } catch (Exception e)
     {
       // Serious problems if this happens.
-      throw new Error("DBRefSource Implementation Exception", e);
+      throw new Error(MessageManager.getString("error.dbrefsource_implementation_exception"), e);
     }
     addDbRefSourceImpl(proxy);
   }
@@ -394,9 +395,7 @@ public class ASequenceFetcher
   {
     if (!jalview.ws.seqfetcher.DbSourceProxy.class.isAssignableFrom(class1))
     {
-      throw new Error(
-              "Implmentation Error - getDbInstances must be given a class that implements jalview.ws.seqfetcher.DbSourceProxy (was given '"
-                      + class1 + "')");
+      throw new Error(MessageManager.formatMessage("error.implementation_error_dbinstance_must_implement_interface", new String[]{class1.toString()}));
     }
     if (FETCHABLEDBS == null)
     {
index f343d5e..617542f 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package org.jibble.epsgraphics;
 
+import jalview.util.MessageManager;
+
 import java.io.*;
 import java.util.*;
 
@@ -157,7 +159,7 @@ public class EpsDocument
       _bufferedWriter.write(line + "\n");
     } catch (IOException e)
     {
-      throw new EpsException("Could not write to the output file: " + e);
+      throw new EpsException(MessageManager.formatMessage("exception.eps_coudnt_write_output_file", new String[]{e.getMessage()}));
     }
   }
 
index c82d4fc..ca1b304 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package org.jibble.epsgraphics;
 
+import jalview.util.MessageManager;
+
 import java.io.*;
 import java.text.*;
 import java.util.*;
@@ -161,9 +163,7 @@ public class EpsGraphics2D extends java.awt.Graphics2D
    */
   private void methodNotSupported()
   {
-    EpsException e = new EpsException(
-            "Method not currently supported by EpsGraphics2D version "
-                    + VERSION);
+    EpsException e = new EpsException(MessageManager.formatMessage("exception.eps_method_not_supported", new String[]{VERSION}));
     e.printStackTrace(System.err);
   }
 
@@ -995,8 +995,7 @@ public class EpsGraphics2D extends java.awt.Graphics2D
         return t.createTransformedShape(_clip);
       } catch (Exception e)
       {
-        throw new EpsException("Unable to get inverse of matrix: "
-                + _transform);
+        throw new EpsException(MessageManager.formatMessage("exception.eps_unable_to_get_inverse_matrix", new String[]{_transform.toString()}));
       }
     }
   }
@@ -1314,7 +1313,7 @@ public class EpsGraphics2D extends java.awt.Graphics2D
       matrix = matrix.createInverse();
     } catch (Exception e)
     {
-      throw new EpsException("Unable to get inverse of matrix: " + matrix);
+        throw new EpsException(MessageManager.formatMessage("exception.eps_unable_to_get_inverse_matrix", new String[]{matrix.toString()}));
     }
     matrix.scale(1, -1);
     matrix.getMatrix(m);
index 3b03d51..2dcbe26 100755 (executable)
@@ -20,6 +20,8 @@
  */
 package uk.ac.ebi.www;
 
+import jalview.util.MessageManager;
+
 public class WSWUBlastServiceLocator extends org.apache.axis.client.Service
         implements uk.ac.ebi.www.WSWUBlastService
 {
@@ -95,10 +97,7 @@ public class WSWUBlastServiceLocator extends org.apache.axis.client.Service
     {
       throw new javax.xml.rpc.ServiceException(t);
     }
-    throw new javax.xml.rpc.ServiceException(
-            "There is no stub implementation for the interface:  "
-                    + (serviceEndpointInterface == null ? "null"
-                            : serviceEndpointInterface.getName()));
+    throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.no_stub_implementation_for_interface", new String[]{(serviceEndpointInterface == null ? "null": serviceEndpointInterface.getName())}));
   }
 
   /**
index 573b9de..855c1fe 100644 (file)
@@ -20,6 +20,8 @@
  */
 package uk.ac.ebi.www.picr.AccessionMappingService;
 
+import jalview.util.MessageManager;
+
 public class AccessionMapperServiceLocator extends
         org.apache.axis.client.Service implements
         uk.ac.ebi.www.picr.AccessionMappingService.AccessionMapperService
@@ -111,10 +113,7 @@ public class AccessionMapperServiceLocator extends
     {
       throw new javax.xml.rpc.ServiceException(t);
     }
-    throw new javax.xml.rpc.ServiceException(
-            "There is no stub implementation for the interface:  "
-                    + (serviceEndpointInterface == null ? "null"
-                            : serviceEndpointInterface.getName()));
+    throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.no_stub_implementation_for_interface", new String[]{(serviceEndpointInterface == null ? "null": serviceEndpointInterface.getName())}));
   }
 
   /**
@@ -175,8 +174,7 @@ public class AccessionMapperServiceLocator extends
     }
     else
     { // Unknown Port Name
-      throw new javax.xml.rpc.ServiceException(
-              " Cannot set Endpoint Address for Unknown Port" + portName);
+      throw new javax.xml.rpc.ServiceException(MessageManager.formatMessage("exception.cannot_set_endpoint_address_unknown_port", new String[]{portName}));
     }
   }
 
index ef14287..d561acb 100644 (file)
@@ -40,17 +40,23 @@ import org.junit.Test;
 public class PDBFileWithJmolTest
 {
   String[] testFile = new String[]
-  { "./examples/1GAQ.txt" }; // , "./examples/DNMT1_MOUSE.pdb" };
+  { "./examples/1GAQ.txt" }; // ,
+
+  // "./examples/DNMT1_MOUSE.pdb"
+  // };
 
   @Test
-   public void testAlignmentLoader() throws Exception
-   {
-    for (String f:testFile) {
+  public void testAlignmentLoader() throws Exception
+  {
+    for (String f : testFile)
+    {
       FileLoader fl = new jalview.io.FileLoader(false);
-      AlignFrame af = fl.LoadFileWaitTillLoaded(f, AppletFormatAdapter.FILE);
+      AlignFrame af = fl
+              .LoadFileWaitTillLoaded(f, AppletFormatAdapter.FILE);
       validateSecStrRows(af.getViewport().getAlignment());
     }
-   }
+  }
+
   @Test
   public void testFileParser() throws Exception
   {
@@ -76,26 +82,36 @@ public class PDBFileWithJmolTest
 
   private void validateSecStrRows(AlignmentI al)
   {
-
     if (!al.isNucleotide())
     {
       for (SequenceI asq : al.getSequences())
       {
         SequenceI sq = asq;
-        while (sq.getDatasetSequence()!=null && sq.getAnnotation()==null)
+        boolean hasDs = false;
+        while (sq.getDatasetSequence() != null
+                && sq.getAnnotation() == null)
         {
-          sq = asq.getDatasetSequence();
+          sq = sq.getDatasetSequence();
+          hasDs = true;
+        }
+        checkFirstAAIsAssoc(sq);
+        if (hasDs)
+        {
+          // also verify if alignment sequence has annotation on it
+          // that is correctly mapped
+          checkFirstAAIsAssoc(asq);
         }
-        assertTrue(
-                "No secondary structure assigned for protein sequence.",
-                sq.getAnnotation() != null
-                        && sq.getAnnotation().length >= 1
-                        && sq.getAnnotation()[0].hasIcons);
-        assertTrue(
-                "Secondary structure not associated for sequence "
-                        + sq.getName(),
-                sq.getAnnotation()[0].sequenceRef == sq);
       }
     }
   }
+
+  private void checkFirstAAIsAssoc(SequenceI sq)
+  {
+    assertTrue("No secondary structure assigned for protein sequence.",
+            sq.getAnnotation() != null && sq.getAnnotation().length >= 1
+                    && sq.getAnnotation()[0].hasIcons);
+    assertTrue(
+            "Secondary structure not associated for sequence "
+                    + sq.getName(), sq.getAnnotation()[0].sequenceRef == sq);
+  }
 }
diff --git a/test/jalview/io/test_gz_fasta_notgz.gz b/test/jalview/io/test_gz_fasta_notgz.gz
new file mode 100644 (file)
index 0000000..63b12b1
--- /dev/null
@@ -0,0 +1,24 @@
+>1PHT
+YQYRALYDYKKEREEDIDLHLGDILTVNKGSLVALGFSDGQEARPEEI--
+--------GWLNGYNETTGERGDFPGTYVEYIG
+>1BB9
+FKVQAQHDYTATDTDELQLKAGDVVLVIP-------FQNP----EEQDEG
+WLMGVKESDWNQHK-ELEKCRGVFPENFTERVQ
+>1UHC
+QVYFAVYTFKARNPNELSVSANQKLKILE-------FKDV----TGNT--
+--------EWWLAE--VNGKKGYVPSNYIRKTE
+>1YCS
+GVIYALWDYEPQNDDELPMKEGDCMTIIH-------REDE----D-EI--
+--------EWWWA--RLNDKEGYVPRNLLGLYP
+>1OOT
+PKAVALYSFAGEESGDLPFRKGDVITILKK-------S------DSQN--
+--------DWWTG--RVNGREGIFPANYVE-LV
+>1ABO
+NLFVALYDFVASGDNTLSITKGEKLRVLG-------YNH-------NG--
+--------EWCEAQ--TKNGQGWVPSNYITPVN
+>1FYN
+TLFVALYDYEARTEDDLSFHKGEKFQILN-------SS--------EG--
+--------DWWEARSLTTGETGYIPSNYVAPVD
+>1QCF
+IIVVALYDYEAIHHEDLSFQKGDQMVVLE-------E---------SG--
+--------EWWKARSLATRKEGYIPSNYVARVD
\ No newline at end of file
index 5a9e954..6f0bf26 100644 (file)
@@ -1,69 +1,60 @@
-/*
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2)
- * Copyright (C) 2014 The Jalview Authors
- * 
- * This file is part of Jalview.
- * 
- * Jalview is free software: you can redistribute it and/or
- * modify it under the terms of the GNU General Public License 
- * as published by the Free Software Foundation, either version 3
- * of the License, or (at your option) any later version.
- *  
- * Jalview is distributed in the hope that it will be useful, but 
- * WITHOUT ANY WARRANTY; without even the implied warranty 
- * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
- * PURPOSE.  See the GNU General Public License for more details.
- * 
- * You should have received a copy of the GNU General Public License
- * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
- * The Jalview Authors are detailed in the 'AUTHORS' file.
- */
-package jalview.ws;
-
-import static org.junit.Assert.*;
-import jalview.datamodel.AlignmentI;
-import jalview.datamodel.SequenceI;
-import jalview.ws.seqfetcher.DbSourceProxy;
-
-import java.util.List;
-
-import org.junit.Before;
-import org.junit.Test;
-
-public class PDBSequenceFetcherTest
-{
-
-  SequenceFetcher sf;
-
-  @Before
-  public void setUp() throws Exception
-  {
-    sf = new SequenceFetcher(false);
-  }
-
-  @Test
-  public void testPdbPerChainRetrieve() throws Exception
-  {
-    List<DbSourceProxy> sps = sf.getSourceProxy("PDB");
-    AlignmentI response = sps.get(0).getSequenceRecords("1QIPA");
-    assertTrue(response != null);
-    assertTrue(response.getHeight() == 1);
-  }
-
-  @Test
-  public void testRnaSeqRetrieve() throws Exception
-  {
-    List<DbSourceProxy> sps = sf.getSourceProxy("PDB");
-    AlignmentI response = sps.get(0).getSequenceRecords("2GIS");
-    assertTrue(response != null);
-    assertTrue(response.getHeight() == 1);
-    for (SequenceI sq : response.getSequences())
-    {
-      assertTrue("No annotation transfered to sequence.",
-              sq.getAnnotation().length > 0);
-      assertTrue("No PDBEntry on sequence.", sq.getPDBId().size() > 0);
-      assertTrue("No RNA annotation on sequence.", sq.getRNA() != null);
-    }
-  }
-
-}
+/*\r
+ * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2)\r
+ * Copyright (C) 2014 The Jalview Authors\r
+ * \r
+ * This file is part of Jalview.\r
+ * \r
+ * Jalview is free software: you can redistribute it and/or\r
+ * modify it under the terms of the GNU General Public License \r
+ * as published by the Free Software Foundation, either version 3\r
+ * of the License, or (at your option) any later version.\r
+ *  \r
+ * Jalview is distributed in the hope that it will be useful, but \r
+ * WITHOUT ANY WARRANTY; without even the implied warranty \r
+ * of MERCHANTABILITY or FITNESS FOR A PARTICULAR \r
+ * PURPOSE.  See the GNU General Public License for more details.\r
+ * \r
+ * You should have received a copy of the GNU General Public License\r
+ * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.\r
+ * The Jalview Authors are detailed in the 'AUTHORS' file.\r
+ */\r
+package jalview.ws;\r
+\r
+import static org.junit.Assert.*;\r
+import jalview.datamodel.AlignmentI;\r
+import jalview.datamodel.SequenceI;\r
+import jalview.ws.seqfetcher.DbSourceProxy;\r
+\r
+import java.util.List;\r
+\r
+import org.junit.Before;\r
+import org.junit.Test;\r
+\r
+public class PDBSequenceFetcherTest\r
+{\r
+\r
+  SequenceFetcher sf;\r
+\r
+  @Before\r
+  public void setUp() throws Exception\r
+  {\r
+    sf = new SequenceFetcher(false);\r
+  }\r
+\r
+  @Test\r
+  public void testRnaSeqRetrieve() throws Exception\r
+  {\r
+    List<DbSourceProxy> sps = sf.getSourceProxy("PDB");\r
+    AlignmentI response = sps.get(0).getSequenceRecords("2GIS");\r
+    assertTrue(response != null);\r
+    assertTrue(response.getHeight() == 1);\r
+    for (SequenceI sq : response.getSequences())\r
+    {\r
+      assertTrue("No annotation transfered to sequence.",\r
+              sq.getAnnotation().length > 0);\r
+      assertTrue("No PDBEntry on sequence.", sq.getPDBId().size() > 0);\r
+      assertTrue("No RNA annotation on sequence.", sq.getRNA() != null);\r
+    }\r
+  }\r
+\r
+}\r
index 64edf44..1e72fae 100644 (file)
@@ -22,6 +22,7 @@ package jalview.ws.gui;
 
 import static org.junit.Assert.*;
 import jalview.gui.WsJobParameters;
+import jalview.util.MessageManager;
 import jalview.ws.jabaws.JalviewJabawsTestUtils;
 import jalview.ws.jws2.JabaPreset;
 import jalview.ws.jws2.Jws2Discoverer;
@@ -205,8 +206,7 @@ public class Jws2ParamView
             }
             WsJobParameters pgui = new WsJobParameters(lastserv,
                     new JabaPreset(lastserv, pr));
-            JFrame jf = new JFrame("Parameters for "
-                    + lastserv.getActionText());
+            JFrame jf = new JFrame(MessageManager.formatMessage("label.ws_parameters_for", new String[]{lastserv.getActionText()}));
             JPanel cont = new JPanel(new BorderLayout());
             pgui.validate();
             cont.setPreferredSize(pgui.getPreferredSize());
diff --git a/test/jalview/ws/jabaws/MinJabawsClientTests.java b/test/jalview/ws/jabaws/MinJabawsClientTests.java
new file mode 100644 (file)
index 0000000..a938dd6
--- /dev/null
@@ -0,0 +1,84 @@
+package jalview.ws.jabaws;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.fail;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.function.Consumer;
+
+import org.junit.Test;
+
+import compbio.data.msa.MsaWS;
+import compbio.data.msa.RegistryWS;
+import compbio.data.sequence.FastaSequence;
+import compbio.metadata.JobStatus;
+import compbio.ws.client.Jws2Client;
+import compbio.ws.client.Services;
+
+public class MinJabawsClientTests {
+
+       /**
+        * simple test for the benefit of JAL-1338
+        * @throws Exception
+        */
+       @SuppressWarnings("rawtypes")
+       @Test
+       public void msaTest() throws Exception {
+               String url;
+               RegistryWS registry = Jws2Client
+                               .connectToRegistry(url = "http://www.compbio.dundee.ac.uk/jabaws");
+               if (registry != null) {
+
+                       MsaWS msaservice = null;
+                       for (Services service : registry.getSupportedServices()) {
+                               if (service.equals(Services.ClustalOWS)) {
+                                       msaservice = (MsaWS) Jws2Client.connect(url, service);
+                                       if (msaservice != null) {
+                                               break;
+                                       }
+                               }
+                       }
+                       if (msaservice == null) {
+                               fail("couldn't find a clustalO service on the public registry");
+                       }
+                       FastaSequence fsq = new FastaSequence("seqA",
+                                       "SESESESESESESESSESESSESESESESESESESESESEEEEEESSESESESESSSSESESESESESESE");
+                       List<FastaSequence> iseqs = new ArrayList<FastaSequence>();
+                       for (int i = 0; i < 9; i++) {
+                               iseqs.add(new FastaSequence(fsq.getId() + i, fsq.getSequence()
+                                               + fsq.getSequence().substring(i + 3, i + 3 + i)));
+                       }
+
+                       String jobid = msaservice.align(iseqs);
+                       if (jobid != null) {
+                               JobStatus js = null;
+                               do {
+                                       try {
+                                               Thread.sleep(500);
+                                       } catch (InterruptedException q) {
+                                       }
+                                       ;
+                                       js = msaservice.getJobStatus(jobid);
+                               } while (!js.equals(JobStatus.FAILED)
+                                               && !js.equals(JobStatus.CANCELLED)
+                                               && !js.equals(JobStatus.FINISHED));
+                               assertEquals("Trial alignment failed. State was " + js.name(),
+                                               js, JobStatus.FINISHED);
+                               assertEquals(
+                                               "Mismatch in number of input and result sequences - assume alignment service wasn't interacted with correctly",
+                                               msaservice.getResult(jobid).getSequences().size(),
+                                               iseqs.size());
+                               msaservice.getResult(jobid).getSequences()
+                                               .forEach(new Consumer<FastaSequence>() {
+                                                       @Override
+                                                       public void accept(FastaSequence t) {
+                                                               System.out.println(">"+t.getId());
+                                                               System.out.println(t.getFormattedFasta());
+                                                       }
+                                               });
+                       }
+
+               }
+       }
+}