/[eiffelstudio]/branches/Eiffel_57_docking/Src/Eiffel/interface/new_graphical/tools/eb_warning_output_tool.e
ViewVC logotype

Contents of /branches/Eiffel_57_docking/Src/Eiffel/interface/new_graphical/tools/eb_warning_output_tool.e

Parent Directory Parent Directory | Revision Log Revision Log


Revision 62103 - (show annotations)
Sun Jul 30 06:39:35 2006 UTC (13 years, 4 months ago) by manus
File size: 3584 byte(s)
EiffelStudio docking branch. It only contains modified classes needed to get the docking version of EiffelStudio.
1 indexing
2 description : "Tool where information warnings are displayed."
3 legal: "See notice at end of class."
4 status: "See notice at end of class."
5 author: ""
6 date: "$Date$"
7 revision: "$Revision$"
8
9 class
10 EB_WARNING_OUTPUT_TOOL
11
12 inherit
13 EB_OUTPUT_TOOL
14 redefine
15 process_warnings, process_errors,
16 is_general,
17 clear
18 end
19
20 create
21 make
22
23 feature -- Basic Operations
24
25 clear is
26 -- Clear window
27 do
28 Precursor {EB_OUTPUT_TOOL}
29 set_title (0)
30 end
31
32 process_errors (errors: LINKED_LIST [ERROR]) is
33 -- Do nothing.
34 do
35 end
36
37 process_warnings (warnings: LINKED_LIST [ERROR]) is
38 -- Display contextual error information from `warnings'.
39 local
40 st: TEXT_FORMATTER
41 retried_count: INTEGER
42 do
43 st := text_area.text_displayed
44 if retried_count = 0 then
45 text_area.handle_before_processing (false)
46 if warnings.is_empty then
47 -- There is no error in the list put a separation before the next message
48 display_separation_line (st)
49 end
50 display_error_list (st, warnings)
51 text_area.handle_after_processing
52 else
53 if retried_count = 1 then
54 -- Most likely a failure in `display_error_list'.
55 text_area.handle_before_processing (false)
56 display_error_error (st)
57 text_area.handle_after_processing
58 else
59 -- Here most likely a failure in `process_text', so
60 -- we clear its content and only display the error message.
61 clear
62 text_area.handle_before_processing (false)
63 display_error_error (st)
64 text_area.handle_after_processing
65 end
66 end
67 set_title (warnings.count)
68 end
69
70 feature {NONE} -- Implementation
71
72 is_general: BOOLEAN is false;
73
74 set_title (a_count: INTEGER) is
75 -- Sets tool title base on `a_count' of warnings
76 require
77 parent_notebook_attached: parent_notebook /= Void
78 widget_attached: widget /= Void
79 local
80 l_name: STRING
81 l_title: STRING
82 do
83 l_name := interface_names.l_tab_warning_output
84 if a_count > 0 then
85 create l_title.make (l_name.count + 6)
86 l_title.append (l_name)
87 l_title.append (" (")
88 l_title.append_integer (a_count)
89 l_title.append_character (')')
90 else
91 l_title := l_name
92 end
93 parent_notebook.set_item_text (widget, l_title)
94 end
95
96 indexing
97 copyright: "Copyright (c) 1984-2006, Eiffel Software"
98 license: "GPL version 2 (see http://www.eiffel.com/licensing/gpl.txt)"
99 licensing_options: "http://www.eiffel.com/licensing"
100 copying: "[
101 This file is part of Eiffel Software's Eiffel Development Environment.
102
103 Eiffel Software's Eiffel Development Environment is free
104 software; you can redistribute it and/or modify it under
105 the terms of the GNU General Public License as published
106 by the Free Software Foundation, version 2 of the License
107 (available at the URL listed under "license" above).
108
109 Eiffel Software's Eiffel Development Environment is
110 distributed in the hope that it will be useful, but
111 WITHOUT ANY WARRANTY; without even the implied warranty
112 of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
113 See the GNU General Public License for more details.
114
115 You should have received a copy of the GNU General Public
116 License along with Eiffel Software's Eiffel Development
117 Environment; if not, write to the Free Software Foundation,
118 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
119 ]"
120 source: "[
121 Eiffel Software
122 356 Storke Road, Goleta, CA 93117 USA
123 Telephone 805-685-1006, Fax 805-685-6869
124 Website http://www.eiffel.com
125 Customer support http://support.eiffel.com
126 ]"
127
128 end -- class EB_WARNING_OUTPUT_TOOL

Properties

Name Value
svn:eol-style native
svn:keywords Author Date ID Revision

  ViewVC Help
Powered by ViewVC 1.1.23