Apply patch #2213 by stikonas, using file #11274

This commit is contained in:
Ignacio R. Morelle 2010-11-21 01:56:29 +00:00
parent 8ee3d4790d
commit d6a3de1938
149 changed files with 242 additions and 242 deletions

View file

@ -22,7 +22,7 @@ twidget* tbuilder_progress_bar::build() const /*@ \label{window_builder.cpp:buil
init_control(widget);
DBG_GUI_G << "Window builder: placed progress bar '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -216,7 +216,7 @@ to chat, create games, and join games.
@namespace network High level network layer for config object transport.
This module provides high level network access using an API similiar
This module provides high level network access using an API similar
to sockets, but primarily for the transport of @ref config objects.
This is how the games protocols work - data is sent via config objects.

View file

@ -246,7 +246,7 @@ bool configuration::parse_side_config(side_number side, const config& original_c
cfg.add_child("ai",aiparam);
}
//backward-compatability hack: put ai_algorithm if it is present
//backward-compatibility hack: put ai_algorithm if it is present
if (const config::attribute_value *v = original_cfg.get("ai_algorithm")) {
config ai_a;
ai_a["ai_algorithm"] = *v;

View file

@ -91,7 +91,7 @@ private:
};
/**
* initalize recruitment recommendations
* initialize recruitment recommendations
*/
void analyze_all();

View file

@ -15,7 +15,7 @@
/**
* @file
* Calculate & analyse attacks of the default ai
* Calculate & analyze attacks of the default ai
*/
#include "../../global.hpp"

View file

@ -505,7 +505,7 @@ variant formula_ai::execute_variant(const variant& var, ai_context &ai_, bool co
}
if( safe_call && (error != variant() || made_moves.empty() || made_moves.back() != action) ){
/*if we have safe_call formula and either error occured, or current action
/*if we have safe_call formula and either error occurred, or current action
*was not reckognized, then evaluate backup formula from safe_call and execute it
*during the next loop
*/

View file

@ -419,7 +419,7 @@ public:
/**
* Modifies AI parameters for active AI of the given @a side.
* This function is provided for backward-compatability with [modify_side][ai]...[/ai][/modify_side]
* This function is provided for backward-compatibility with [modify_side][ai]...[/ai][/modify_side]
* It can only add new facets to aspects
* @param side side_number (1-based, as in game_info).
* @param ai_parameters AI parameters to be modified.

View file

@ -1403,7 +1403,7 @@ void get_villages_phase::dispatch_complex(
// Evaluate and start correct function.
if(perfect) {
// We did a perfect dispatch 2 units who could visit 2 villages.
// This means we didn't change the assertion for this funtions
// This means we didn't change the assertion for this functions
// so call ourselves recursively, and finish afterwards.
DBG_AI_TESTING_AI_DEFAULT << "Perfect dispatch, do complex again.\n";
dispatch_complex(reachmap, moves, village_count - 2);

View file

@ -43,7 +43,7 @@ fallback_to_other_ai::fallback_to_other_ai( ai_context &context, const config &c
void fallback_to_other_ai::on_create()
{
config ai_cfg = cfg_.child_or_empty("ai");
///@deprecated 1.9.3 backward-compatability hack - try to update the old default ai config.
///@deprecated 1.9.3 backward-compatibility hack - try to update the old default ai config.
std::string ai_algorithm = ai_cfg["ai_algorithm"];
if ((ai_algorithm.empty()) || (ai_algorithm=="default_ai")) {
if (configuration::parse_side_config(get_side(),cfg_,ai_cfg)) {

View file

@ -529,7 +529,7 @@ namespace ana
* The time parameter indicates how long you are willing to wait.
*
* If a message is received before this time period then this call will be insignificant.
* However, if no such message is received, the appropiate call to handle_receive will be
* However, if no such message is received, the appropriate call to handle_receive will be
* made with ana::timeout_error as the error_code parameter.
*
* @param id : The ana::net_id of the client you are expecting the message from. If the
@ -594,7 +594,7 @@ namespace ana
*
* If a message is received before this time period then this call will be
* insignificant.
* However, if no such message is received, the appropiate call to handle_receive will
* However, if no such message is received, the appropriate call to handle_receive will
* be made with ana::timeout_error as the error_code parameter.
*
* Use the methods described in the ana::time namespace to create time lapses.
@ -715,7 +715,7 @@ namespace ana
* The time parameter indicates how long you are willing to wait.
*
* If a message is received before this time period then this call will be insignificant.
* However, if no such message is received, the appropiate call to handle_receive will be
* However, if no such message is received, the appropriate call to handle_receive will be
* made with ana::timeout_error as the error_code parameter.
*
* Use the methods described in the ana::time namespace to create time lapses.

View file

@ -25,7 +25,7 @@
class battle_context_unit_stats;
// This encapsulates all we need to know for this combat.
/** All combat-related infos. */
/** All combat-related info. */
struct combatant
{
/** Construct a combatant. */

View file

@ -269,7 +269,7 @@ void terrain_builder::rebuild_terrain(const map_location &loc)
img_loc.start_animation(0, true);
btile.images_background.push_back(img_loc);
//Combine base and overlay image if neccessary
//Combine base and overlay image if necessary
if(map().get_terrain_info(map().get_terrain(loc)).is_combined()) {
const std::string filename_ovl =
map().get_terrain_info(map().get_terrain(loc)).minimap_image_overlay();

View file

@ -116,7 +116,7 @@ public:
* Will be used if some images specify several
* time-of-day- related variants.
* @param terrain_type BACKGROUND or FOREGROUND,
* depending on wheter we ask for the terrain which is
* depending on whether we ask for the terrain which is
* before, or after the unit sprite.
*
* @return Returns a pointer list of animated images corresponding

View file

@ -26,7 +26,7 @@
*
* @param text The text to copy.
* @param mouse Is the selection done by the mouse? On UNIX systems there
* are multiple clipboards and the mouse selction uses a
* are multiple clipboards and the mouse selection uses a
* different clipboard. Ignored on other systems.
*/
void copy_to_clipboard(const std::string& text, const bool mouse);

View file

@ -35,7 +35,7 @@ namespace game_config {
/**
* Used to set and unset scoped defines to preproc_map
* This is prefered form to set defines that aren't global
* This is preferred form to set defines that aren't global
**/
template <class T>
class scoped_preproc_define_internal : private boost::noncopyable {

View file

@ -78,7 +78,7 @@ protected:
/**
* Process mouse- and keypress-events from SDL.
* Not virtual but calls various virtual function to allow specialized
* behaviour of derived classess.
* behaviour of derived classes.
*/
void handle_event(const SDL_Event& event);
@ -89,19 +89,19 @@ protected:
/**
* Process keydown (always).
* Overriden in derived classes
* Overridden in derived classes
*/
virtual void process_keydown_event(const SDL_Event& event);
/**
* Process keyup (always).
* Overriden in derived classes
* Overridden in derived classes
*/
virtual void process_keyup_event(const SDL_Event& event);
/**
* Called after processing a mouse button up or down event
* Overriden in derived classes
* Overridden in derived classes
*/
virtual void post_mouse_press(const SDL_Event& event);

View file

@ -316,7 +316,7 @@ const map_location display::pixel_position_to_hex(int x, int y) const
// NOTE: This code to get nearest_hex and second_nearest_hex
// is not used anymore. However, it can be usefull later.
// is not used anymore. However, it can be useful later.
// So, keep it here for the moment.
/*
if(nearest_hex != NULL) {
@ -874,7 +874,7 @@ inline display::drawing_buffer_key::drawing_buffer_key(const map_location &loc,
BOOST_STATIC_ASSERT(SHIFT_LAYER_GROUP + BITS_FOR_LAYER_GROUP == sizeof(key_) * 8);
// the parity of x must be more significant than the layer but less significant than y.
// Thus basically every row is splitted in two: First the row containing all the odd x
// Thus basically every row is split in two: First the row containing all the odd x
// then the row containing all the even x. Since thus the least significant bit of x is
// not required for x ordering anymore it can be shifted out to the right.
const unsigned int x_parity = static_cast<unsigned int>(loc.x) & 1;
@ -1008,7 +1008,7 @@ void display::update_display()
flabel.set_font_size(12);
flabel.set_color(benchmark ? font::BAD_COLOR : font::NORMAL_COLOR);
flabel.set_position(10, 100);
flabel.set_alignement(font::LEFT_ALIGN);
flabel.set_alignment(font::LEFT_ALIGN);
fps_handle_ = font::add_floating_label(flabel);
}

View file

@ -302,7 +302,7 @@ public:
/**
* Per-location invalidation called by invalidate_animations()
* defaults to no action, overriden by derived classes
* defaults to no action, overridden by derived classes
*/
virtual void invalidate_animations_location(const map_location& /*loc*/) {}
@ -808,7 +808,7 @@ protected:
void draw_init();
void draw_wrap(bool update,bool force);
/** Used to indicate to drawing funtions that we are doing a map screenshot */
/** Used to indicate to drawing functions that we are doing a map screenshot */
bool map_screenshot_;
public: //operations for the arrow framework

View file

@ -201,7 +201,7 @@ editor_action_fill* editor_action_fill::clone() const
}
editor_action_paint_area* editor_action_fill::perform(map_context& mc) const
{
std::set<map_location> to_fill = mc.get_map().get_contigious_terrain_tiles(loc_);
std::set<map_location> to_fill = mc.get_map().get_contiguous_terrain_tiles(loc_);
util::unique_ptr<editor_action_paint_area> undo(new editor_action_paint_area(to_fill, mc.get_map().get_terrain(loc_)));
mc.draw_terrain(t_, to_fill, one_layer_);
mc.set_needs_terrain_rebuild();
@ -209,7 +209,7 @@ editor_action_paint_area* editor_action_fill::perform(map_context& mc) const
}
void editor_action_fill::perform_without_undo(map_context& mc) const
{
std::set<map_location> to_fill = mc.get_map().get_contigious_terrain_tiles(loc_);
std::set<map_location> to_fill = mc.get_map().get_contiguous_terrain_tiles(loc_);
mc.draw_terrain(t_, to_fill, one_layer_);
mc.set_needs_terrain_rebuild();
}

View file

@ -143,13 +143,13 @@ class editor_action_chain : public editor_action
bool empty() const;
/**
* Remove the last added action and return it, transfering
* Remove the last added action and return it, transferring
* ownership to the caller
*/
editor_action* pop_last_action();
/**
* Remove the first added action and return it, transfering
* Remove the first added action and return it, transferring
* ownership to the caller
*/
editor_action* pop_first_action();

View file

@ -81,7 +81,7 @@ class editor_action
* A textual description of the action. For use
* e.g. in the undo menu, to have a "Undo: Fill with
* Grassland" item rather than just "Undo". Should be
* overriden by derived Actions, defaults to a debug
* overridden by derived Actions, defaults to a debug
* message.
*/
virtual std::string get_description() const;

View file

@ -187,7 +187,7 @@ class editor_controller : public controller_base,
/**
* Check if a map is already open.
* @return index of the map context containg the given filename,
* @return index of the map context containing the given filename,
* or map_contexts_.size() if not found.
*/
size_t check_open_map(const std::string& fn) const;

View file

@ -40,7 +40,7 @@ public:
protected:
void pre_draw();
/**
* The editor uses different rules for terrain highligting (e.g. selections)
* The editor uses different rules for terrain highlighting (e.g. selections)
*/
image::TYPE get_image_type(const map_location& loc);

View file

@ -121,7 +121,7 @@ void editor_map::sanity_check()
}
}
std::set<map_location> editor_map::get_contigious_terrain_tiles(const map_location& start) const
std::set<map_location> editor_map::get_contiguous_terrain_tiles(const map_location& start) const
{
t_translation::t_terrain terrain = get_terrain(start);
std::set<map_location> result;

View file

@ -111,11 +111,11 @@ public:
void sanity_check();
/**
* Get a contigious set of tiles having the same terrain as the starting location.
* Get a contiguous set of tiles having the same terrain as the starting location.
* Useful for flood fill or magic wand selection
* @return a contigious set of locations that will always contain at least the starting element
* @return a contiguous set of locations that will always contain at least the starting element
*/
std::set<map_location> get_contigious_terrain_tiles(const map_location& start) const;
std::set<map_location> get_contiguous_terrain_tiles(const map_location& start) const;
/**
* Set labels for staring positions in the given display object.

View file

@ -298,7 +298,7 @@ std::set<map_location> mouse_action_select::affected_hexes(
editor_display& disp, const map_location& hex)
{
if (has_shift_modifier()) {
return disp.map().get_contigious_terrain_tiles(hex);
return disp.map().get_contiguous_terrain_tiles(hex);
} else {
return brush_drag_mouse_action::affected_hexes(disp, hex);
}
@ -374,7 +374,7 @@ void mouse_action_paste::set_mouse_overlay(editor_display& disp)
std::set<map_location> mouse_action_fill::affected_hexes(
editor_display& disp, const map_location& hex)
{
return disp.map().get_contigious_terrain_tiles(hex);
return disp.map().get_contiguous_terrain_tiles(hex);
}
editor_action* mouse_action_fill::click_left(editor_display& disp, int x, int y)
@ -384,7 +384,7 @@ editor_action* mouse_action_fill::click_left(editor_display& disp, int x, int y)
terrain_left_ = disp.map().get_terrain(hex);
return NULL;
} else {
//TODO only take the base terrain into account when searching for contigious terrain when painting base only
//TODO only take the base terrain into account when searching for contiguous terrain when painting base only
//or use a different key modifier for that
editor_action_fill* a = new editor_action_fill(hex, terrain_left_, has_shift_modifier());
return a;
@ -399,7 +399,7 @@ editor_action* mouse_action_fill::click_right(editor_display& disp, int x, int y
terrain_right_ = disp.map().get_terrain(hex);
return NULL;
} else {
//TODO only take the base terrain into account when searching for contigious terrain when painting base only
//TODO only take the base terrain into account when searching for contiguous terrain when painting base only
//or use a different key modifier for that
editor_action_fill* a = new editor_action_fill(hex, terrain_right_, has_shift_modifier());
return a;

View file

@ -64,22 +64,22 @@ public:
virtual std::set<map_location> affected_hexes(editor_display& disp, const map_location& hex);
/**
* A click, possibly the beginning of a drag. Must be overriden.
* A click, possibly the beginning of a drag. Must be overridden.
*/
virtual editor_action* click_left(editor_display& disp, int x, int y) = 0;
/**
* A click, possibly the beginning of a drag. Must be overriden.
* A click, possibly the beginning of a drag. Must be overridden.
*/
virtual editor_action* click_right(editor_display& disp, int x, int y) = 0;
/**
* Drag operation. A click should have occured earlier. Defaults to no action.
* Drag operation. A click should have occurred earlier. Defaults to no action.
*/
virtual editor_action* drag_left(editor_display& disp, int x, int y, bool& partial, editor_action* last_undo);
/**
* Drag operation. A click should have occured earlier. Defaults to no action.
* Drag operation. A click should have occurred earlier. Defaults to no action.
*/
virtual editor_action* drag_right(editor_display& disp, int x, int y, bool& partial, editor_action* last_undo);
@ -281,7 +281,7 @@ public:
}
/**
* Overriden to allow special behaviour based on modifier keys
* Overridden to allow special behaviour based on modifier keys
*/
std::set<map_location> affected_hexes(editor_display& disp, const map_location& hex);

View file

@ -70,7 +70,7 @@ namespace gui{
font::floating_label flabel(label_string_);
flabel.set_color(font::YELLOW_COLOR);
flabel.set_position(area.x + border_size, ypos);
flabel.set_alignement(font::LEFT_ALIGN);
flabel.set_alignment(font::LEFT_ALIGN);
flabel.set_clip_rect(area);
label_ = font::add_floating_label(flabel);

View file

@ -158,7 +158,7 @@ public:
// set width for word wrapping (use -1 to disable it)
void set_width(int w) {width_ = w;}
void set_clip_rect(const SDL_Rect& r) {clip_rect_ = r;}
void set_alignement(ALIGN align) {align_ = align;}
void set_alignment(ALIGN align) {align_ = align;}
void set_scroll_mode(LABEL_SCROLL_MODE scroll) {scroll_ = scroll;}
void use_markup(bool b) {use_markup_ = b;}

View file

@ -1088,7 +1088,7 @@ formula::formula(const std::string& str, function_symbol_table* symbols) :
tokens.back().line_number = files.back().second;
}
} catch(token_error& e) {
//when we catch token error, we should write whole line in which error occured, so we merge info from token and everything we had in the line so far
//when we catch token error, we should write whole line in which error occurred, so we merge info from token and everything we had in the line so far
std::string str = "";
if(!tokens.empty()) {
token* tok_it = &tokens[0] + tokens.size()-1;

View file

@ -401,7 +401,7 @@ void game_display::draw_hex(const map_location& loc)
image::get_image(selected, image::SCALED_TO_HEX));
}
// Show def% and turn to reach infos
// Show def% and turn to reach info
if(!is_shrouded && on_map) {
draw_movement_info(loc);
}
@ -1412,7 +1412,7 @@ void game_display::add_chat_message(const time_t& time, const std::string& speak
spk_flabel.set_color(speaker_color);
spk_flabel.set_position(rect.x + chat_message_x, rect.y + ypos);
spk_flabel.set_clip_rect(rect);
spk_flabel.set_alignement(font::LEFT_ALIGN);
spk_flabel.set_alignment(font::LEFT_ALIGN);
spk_flabel.set_bg_color(chat_message_bg);
spk_flabel.set_border_size(chat_message_border);
spk_flabel.use_markup(false);
@ -1425,7 +1425,7 @@ void game_display::add_chat_message(const time_t& time, const std::string& speak
msg_flabel.set_position(rect.x + chat_message_x + font::get_floating_label_rect(speaker_handle).w,
rect.y + ypos);
msg_flabel.set_clip_rect(rect);
msg_flabel.set_alignement(font::LEFT_ALIGN);
msg_flabel.set_alignment(font::LEFT_ALIGN);
msg_flabel.set_bg_color(chat_message_bg);
msg_flabel.set_border_size(chat_message_border);
msg_flabel.use_markup(false);

View file

@ -103,7 +103,7 @@ public:
/**
* Sets the paths that are currently displayed as available
* for the unit to move along.
* All other paths will be greyed out.
* All other paths will be grayed out.
*/
void highlight_reach(const pathfind::paths &paths_list);
@ -268,7 +268,7 @@ public:
const unit_map& get_const_units() const {return units_;}
/**
* annotate hex with number, useful for debugging or UI protoype
* annotate hex with number, useful for debugging or UI prototype
*/
static int& debug_highlight(const map_location& loc);
static void clear_debug_highlights() { debugHighlights_.clear(); }

View file

@ -256,7 +256,7 @@ tline::tline(const config& cfg)
* text_maximum_height unsigned The maximum height available for the text
* on the widget.
* text_wrap_mode int When the text doesn't fit in the
* available width there are serveral ways
* available width there are several ways
* to fix that. This variable holds the
* best method. (NOTE this is a 'hidden'
* variable meant to copy state from a
@ -447,7 +447,7 @@ tline::tline(const config& cfg)
* about the section should describe the
* section in further detail.
*
* grid A grid contains serveral widgets. (TODO
* grid A grid contains several widgets. (TODO
* add link to generic grid page.)
* @end_table
*/
@ -1225,7 +1225,7 @@ void tcanvas::parse_cfg(const config& cfg)
shapes_.push_back(new ttext(data));
} else if(type == "pre_commit") {
/* note this should get splitted if more preprocessing is used. */
/* note this should get split if more preprocessing is used. */
foreach(const config::any_child& function,
data.all_children_range()) {

View file

@ -209,7 +209,7 @@ public:
* * post_child The callbacks for the parent container to be called after
* the child.
*
* For every queue it's posible to add a new event in the front or in the
* For every queue it's possible to add a new event in the front or in the
* back.
*
* Whether all three queues are executed depend on the whether the
@ -506,7 +506,7 @@ public:
, const T& signal)
{
/*
* The function doesn't differenciate between front and back
* The function doesn't differentiate between front and back
* position so fall down from front to back.
*/
switch(position) {

View file

@ -214,7 +214,7 @@ struct tdispatcher_implementation
}
/**
* A helper class to find out wheter dispatcher has an handler for a
* A helper class to find out whether dispatcher has an handler for a
* certain event.
*/
class thas_handler

View file

@ -49,7 +49,7 @@ thorizontal_scrollbar_definition::tresolution::tresolution(const config& cfg)
* The resolution for a horizontal scrollbar also contains the following keys:
* @start_table = config
* minimum_positioner_length (unsigned)
* The minumum size the positioner is
* The minimum size the positioner is
* allowed to be. The engine needs to know
* this in order to calculate the best size
* for the positioner.

View file

@ -47,7 +47,7 @@ tslider_definition::tresolution::tresolution(const config& cfg)
*
* @start_table = config
* minimum_positioner_length (unsigned)
* The minumum size the positioner is
* The minimum size the positioner is
* allowed to be. The engine needs to know
* this in order to calculate the best size
* for the positioner.

View file

@ -44,7 +44,7 @@ tstacked_widget_definition::tresolution::tresolution(const config& cfg)
* A stacked widget holds several widgets on top of eachother. This can be used
* for various effects; add an optional overlay to an image, stack it with a
* spacer to force a minimum size of a widget. The latter is handy to avoid
* making a seperate definition for a single instance with a fixed size.
* making a separate definition for a single instance with a fixed size.
*
* A stacked widget has no states.
*/

View file

@ -50,7 +50,7 @@ tvertical_scrollbar_definition::tresolution::tresolution(const config& cfg)
* The resolution for a vertical scrollbar also contains the following keys:
* @start_table = config
* minimum_positioner_length (unsigned)
* The minumum size the positioner is
* The minimum size the positioner is
* allowed to be. The engine needs to know
* this in order to calculate the best size
* for the positioner.

View file

@ -42,7 +42,7 @@ twidget* tbuilder_button::build() const
widget->set_retval(get_retval(retval_id_, retval_, id));
DBG_GUI_G << "Window builder: placed button '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -28,18 +28,18 @@ namespace gui2 {
namespace implementation {
/**
* Returns the vertical alignement.
* Returns the vertical alignment.
*
* @param v_align The string representing the alignement.
* @param v_align The string representing the alignment.
*
* @returns The alignment.
*/
unsigned get_v_align(const std::string& v_align);
/**
* Returns the horizontal alignement.
* Returns the horizontal alignment.
*
* @param h_align The string representing the alignement.
* @param h_align The string representing the alignment.
*
* @returns The alignment.
*/

View file

@ -95,7 +95,7 @@ twidget* tbuilder_horizontal_listbox::build() const
widget->set_horizontal_scrollbar_mode(horizontal_scrollbar_mode);
DBG_GUI_G << "Window builder: placed listbox '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
boost::intrusive_ptr<const tlistbox_definition::tresolution> conf =

View file

@ -37,7 +37,7 @@ twidget* tbuilder_horizontal_scrollbar::build() const
DBG_GUI_G << "Window builder:"
<< " placed horizontal scrollbar '" << id
<< "' with defintion '" << definition
<< "' with definition '" << definition
<< "'.\n";
return widget;

View file

@ -37,7 +37,7 @@ twidget* tbuilder_image::build() const
init_control(widget);
DBG_GUI_G << "Window builder: placed image '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -42,7 +42,7 @@ twidget* tbuilder_label::build() const
widget->set_text_alignment(text_alignment);
DBG_GUI_G << "Window builder: placed label '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -109,7 +109,7 @@ twidget* tbuilder_listbox::build() const
widget->set_horizontal_scrollbar_mode(horizontal_scrollbar_mode);
DBG_GUI_G << "Window builder: placed listbox '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
boost::intrusive_ptr<const tlistbox_definition::tresolution> conf =

View file

@ -37,7 +37,7 @@ twidget* tbuilder_minimap::build() const
init_control(widget);
DBG_GUI_G << "Window builder: placed minimap '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -72,7 +72,7 @@ twidget* tbuilder_multi_page::build() const
widget->set_page_builder(builder);
DBG_GUI_G << "Window builder: placed multi_page '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
boost::intrusive_ptr<const tmulti_page_definition::tresolution> conf =
@ -94,7 +94,7 @@ twidget* tbuilder_multi_page::build() const
/*WIKI_MACRO
* @start_macro = multi_page_description
*
* A multi page is a control that contains serveral 'pages' of which
* A multi page is a control that contains several 'pages' of which
* only one is visible. The pages can contain the same of different
* info.
* @end_macro

View file

@ -45,7 +45,7 @@ twidget* tbuilder_panel::build() const
init_control(widget);
DBG_GUI_G << "Window builder: placed panel '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
widget->init_grid(grid);

View file

@ -49,7 +49,7 @@ twidget* tbuilder_password_box::build() const
}
DBG_GUI_G << "Window builder: placed password box '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -37,7 +37,7 @@ twidget* tbuilder_progress_bar::build() const
init_control(widget);
DBG_GUI_G << "Window builder: placed progress bar '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -37,7 +37,7 @@ twidget* tbuilder_repeating_button::build() const
init_control(widget);
DBG_GUI_G << "Window builder: placed repeating button '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -54,7 +54,7 @@ twidget* tbuilder_scroll_label::build() const
widget->finalize_setup();
DBG_GUI_G << "Window builder: placed scroll label '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -54,7 +54,7 @@ twidget* tbuilder_scrollbar_panel::build() const
widget->set_horizontal_scrollbar_mode(horizontal_scrollbar_mode);
DBG_GUI_G << "Window builder: placed scrollbar_panel '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
boost::intrusive_ptr<

View file

@ -73,7 +73,7 @@ twidget* tbuilder_slider::build() const
}
DBG_GUI_G << "Window builder: placed slider '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -48,7 +48,7 @@ twidget* tbuilder_spacer::build() const
}
DBG_GUI_G << "Window builder: placed spacer '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -47,7 +47,7 @@ twidget* tbuilder_stacked_widget::build() const
init_control(widget);
DBG_GUI_G << "Window builder: placed stacked widget '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
boost::intrusive_ptr<const tstacked_widget_definition::tresolution> conf =

View file

@ -45,7 +45,7 @@ twidget* tbuilder_text_box::build() const
}
DBG_GUI_G << "Window builder: placed text box '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -44,7 +44,7 @@ twidget* tbuilder_toggle_button::build() const
widget->set_retval(get_retval(retval_id_, retval_, id));
DBG_GUI_G << "Window builder: placed toggle button '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
return widget;

View file

@ -50,7 +50,7 @@ twidget* tbuilder_toggle_panel::build() const
widget->set_retval(get_retval(retval_id_, retval_, id));
DBG_GUI_G << "Window builder: placed toggle panel '"
<< id << "' with defintion '"
<< id << "' with definition '"
<< definition << "'.\n";
widget->init_grid(grid);

View file

@ -38,7 +38,7 @@ twidget* tbuilder_vertical_scrollbar::build() const
DBG_GUI_G << "Window builder:"
<< " placed vertical scrollbar '" << id
<< "' with defintion '" << definition
<< "' with definition '" << definition
<< "'.\n";
return widget;

View file

@ -56,7 +56,7 @@ private:
/** Campaign list. */
const std::vector<config> &campaigns_;
/** The choosen campaign. */
/** The chosen campaign. */
int choice_;
};

View file

@ -240,7 +240,7 @@ private:
void add_active_window_message(const std::string& sender, const std::string& message);
/**
* Switch to the window given by a vaild pointer (e.g. received from a call
* Switch to the window given by a valid pointer (e.g. received from a call
* to *_window_open)
*/
void switch_to_window(tlobby_chat_window* t);

View file

@ -31,7 +31,7 @@ namespace gui2 {
REGISTER_WINDOW(message)
/**
* Helper to implement private functions without modifing the header.
* Helper to implement private functions without modifying the header.
*
* The class is a helper to avoid recompilation and only has static
* functions.

View file

@ -44,13 +44,13 @@ void twml_message_::set_input(const std::string& caption,
}
void twml_message_::set_option_list(
const std::vector<std::string>& option_list, int* choosen_option)
const std::vector<std::string>& option_list, int* chosen_option)
{
assert(!option_list.empty());
assert(choosen_option);
assert(chosen_option);
option_list_ = option_list;
chosen_option_ = choosen_option;
chosen_option_ = chosen_option;
}
/**

View file

@ -57,7 +57,7 @@ public:
std::string* text, const unsigned maximum_length);
void set_option_list(
const std::vector<std::string>& option_list, int* choosen_option);
const std::vector<std::string>& option_list, int* chosen_option);
private:

View file

@ -171,7 +171,7 @@ public:
/**
* Inherited from twidget.
*
* This function sets the defintion of a control and should be called soon
* This function sets the definition of a control and should be called soon
* after creating the object since a lot of internal functions depend on the
* definition.
*

View file

@ -37,7 +37,7 @@ class twindow;
* sizing algorithm.
*
* This class needs to be friends with a lot of classes so it can view the
* private data in the class. This design is choosen so the debug info can be
* private data in the class. This design is chosen so the debug info can be
* put in a separate class instead of adding the info via virtual functions in
* the classes themselves. Also adding 'friend class foo' doesn't need to
* include the header declaring foo, so it avoids header cluttage.

View file

@ -185,7 +185,7 @@ void thorizontal_list::set_visible_area(const SDL_Rect& area)
{
/*
* Note for most implementations this function could work only for the
* tindependant class it probably fails. Evalute to make a generic
* tindependent class it probably fails. Evaluate to make a generic
* function in the tgenerator template class and call it from the wanted
* placement functions.
*/
@ -378,7 +378,7 @@ void tvertical_list::set_visible_area(const SDL_Rect& area)
{
/*
* Note for most implementations this function could work only for the
* tindependant class it probably fails. Evalute to make a generic
* tindependent class it probably fails. Evalute to make a generic
* function in the tgenerator template class and call it from the wanted
* placement functions.
*/
@ -482,7 +482,7 @@ void tvertical_list::handle_key_down_arrow(SDLMod /*modifier*/, bool& handled)
}
}
void tindependant::request_reduce_width(const unsigned maximum_width)
void tindependent::request_reduce_width(const unsigned maximum_width)
{
for(size_t i = 0; i < get_item_count(); ++i) {
@ -491,7 +491,7 @@ void tindependant::request_reduce_width(const unsigned maximum_width)
}
}
void tindependant::request_reduce_height(const unsigned maximum_height)
void tindependent::request_reduce_height(const unsigned maximum_height)
{
for(size_t i = 0; i < get_item_count(); ++i) {
@ -500,7 +500,7 @@ void tindependant::request_reduce_height(const unsigned maximum_height)
}
}
tpoint tindependant::calculate_best_size() const
tpoint tindependent::calculate_best_size() const
{
/*
* The best size is the combination of the greatest width and greatest
@ -525,7 +525,7 @@ tpoint tindependant::calculate_best_size() const
return result;
}
void tindependant::place(const tpoint& origin, const tpoint& size)
void tindependent::place(const tpoint& origin, const tpoint& size)
{
for(size_t i = 0; i < get_item_count(); ++i) {
@ -534,7 +534,7 @@ void tindependant::place(const tpoint& origin, const tpoint& size)
}
}
void tindependant::set_origin(const tpoint& origin)
void tindependent::set_origin(const tpoint& origin)
{
/*
* Set the origin for every item.
@ -549,7 +549,7 @@ void tindependant::set_origin(const tpoint& origin)
}
}
twidget* tindependant::find_at(const tpoint& coordinate
twidget* tindependent::find_at(const tpoint& coordinate
, const bool must_be_active)
{
assert(get_window());
@ -563,7 +563,7 @@ twidget* tindependant::find_at(const tpoint& coordinate
return grid.find_at(coordinate, must_be_active);
}
const twidget* tindependant::find_at(const tpoint& coordinate
const twidget* tindependent::find_at(const tpoint& coordinate
, const bool must_be_active) const
{
assert(get_window());
@ -577,7 +577,7 @@ const twidget* tindependant::find_at(const tpoint& coordinate
return grid.find_at(coordinate, must_be_active);
}
twidget* tindependant::find(
twidget* tindependent::find(
const std::string& id, const bool must_be_active)
{
for(size_t i = 0; i < get_item_count(); ++i) {
@ -590,7 +590,7 @@ twidget* tindependant::find(
return NULL;
}
const twidget* tindependant::find(
const twidget* tindependent::find(
const std::string& id, const bool must_be_active) const
{
for(size_t i = 0; i < get_item_count(); ++i) {
@ -605,7 +605,7 @@ const twidget* tindependant::find(
return NULL;
}
void tindependant::set_visible_area(const SDL_Rect& area)
void tindependent::set_visible_area(const SDL_Rect& area)
{
/*
* Set the visible area for every item.
@ -734,11 +734,11 @@ switch(placement) { \
, select \
>; \
break; \
case tgenerator_::independant : \
case tgenerator_::independent : \
result = new tgenerator \
< minimum \
, maximum \
, policy::placement::tindependant \
, policy::placement::tindependent \
, select \
>; \
break; \

View file

@ -49,7 +49,7 @@ public:
{ horizontal_list
, vertical_list
, grid
, independant
, independent
};
/**
@ -123,7 +123,7 @@ public:
* Returns the selected item.
*
* If a list has multiple selected items it looks whether it knows the last
* item acutally selected, if that item is selected that one is choosen.
* item acutally selected, if that item is selected that one is chosen.
* Else is goes through all selected items and returns the first one
* selected.
*

View file

@ -401,7 +401,7 @@ struct tmatrix
*
* @todo Implement.
*/
struct tindependant
struct tindependent
: public virtual tgenerator_
{
/** See thorizontal_list::create_item(). */
@ -569,7 +569,7 @@ public:
assert(index < items_.size());
// Might be other parts of the engine want to know about the
// deselction, if minimum fails it gets another chance later on,
// deselection, if minimum fails it gets another chance later on,
// since it deletes the item.
if(is_selected(index)) {
select_item(index, false);
@ -913,7 +913,7 @@ private:
/**
* Is the row shown or not.
*
* This flag is used the help to set the visible flag, it's prefered to
* This flag is used the help to set the visible flag, it's preferred to
* test this flag for external functions.
*
* @todo functions now test for visible and shown, that can use some

View file

@ -38,7 +38,7 @@
namespace gui2 {
/**
* Helper to implement private functions without modifing the header.
* Helper to implement private functions without modifying the header.
*
* The class is a helper to avoid recompilation and only has static
* functions.

View file

@ -129,7 +129,7 @@ std::string encode_text_alignment(const PangoAlignment alignment);
unsigned decode_font_style(const std::string& style);
/**
* Returns a default error message if a mandatory widget is ommited.
* Returns a default error message if a mandatory widget is omitted.
*
* @param id The id of the omitted widget.
* @returns The error message.

View file

@ -132,7 +132,7 @@ public:
*
* Use this version if you want to show hide multiple items since it's
* optimized for that purpose, for one it calls the selection changed
* callback only once instead of serveral times.
* callback only once instead of several times.
*
* @param shown A vector with the show hide status for every
* row. The number of items in the vector must

View file

@ -37,7 +37,7 @@ namespace gui2 {
REGISTER_WIDGET(listbox)
namespace {
// in seperate namespace to avoid name classes
// in separate namespace to avoid name classes
REGISTER_WIDGET3(tlistbox_definition, horizontal_listbox, _4)
void callback_list_item_clicked(twidget* caller)

View file

@ -123,7 +123,7 @@ public:
*
* Use this version if you want to show hide multiple items since it's
* optimized for that purpose, for one it calls the selection changed
* callback only once instead of serveral times.
* callback only once instead of several times.
*
* @param shown A vector with the show hide status for every
* row. The number of items in the vector must

View file

@ -33,7 +33,7 @@ tmulti_page::tmulti_page()
, page_builder_(NULL)
{
generator_ = tgenerator_::build(
true, true, tgenerator_::independant, false);
true, true, tgenerator_::independent, false);
}
void tmulti_page::add_page(const string_map& item)

View file

@ -256,7 +256,7 @@ private:
virtual int on_bar(const tpoint& coordinate) const = 0;
/**
* Gets the relevent difference in between the two positions.
* Gets the relevant difference in between the two positions.
*
* This function is used to determine how much the positioner needs to be
* moved.

View file

@ -36,7 +36,7 @@
namespace gui2 {
/**
* Helper to implement private functions without modifing the header.
* Helper to implement private functions without modifying the header.
*
* The class is a helper to avoid recompilation and only has static
* functions.

View file

@ -180,9 +180,9 @@ const std::string& tgui_definition::read(const config& cfg)
* id (string) Unique id for this gui (theme).
* description (t_string) Unique translatable name for this gui.
*
* widget_definitions (section) The defintions of all
* widget_definitions (section) The definitions of all
* [[#widget_list|widgets]].
* window (section) The defintions of all
* window (section) The definitions of all
* [[#window_list|windows]].
* settings (section) The settings for the gui.
* @end_table
@ -560,7 +560,7 @@ std::vector<twindow_builder::tresolution>::const_iterator get_window_builder(con
if(true) { // FIXME Test for default gui.
assert(window != current_gui->second.window_types.end());
} else {
// FIXME Get the defintion in the default gui and do an assertion test.
// FIXME Get the definition in the default gui and do an assertion test.
}
for(std::vector<twindow_builder::tresolution>::const_iterator

View file

@ -34,7 +34,7 @@ tstacked_widget::tstacked_widget()
, generator_(NULL)
{
generator_ = tgenerator_::build(
false, false, tgenerator_::independant, false);
false, false, tgenerator_::independent, false);
}
void tstacked_widget::layout_children()

View file

@ -220,7 +220,7 @@ private:
* Alt The alt key is pressed.
*
* If modifiers together do something else as the sum of the modifiers
* it's listed seperately eg.
* it's listed separately eg.
*
* Control Moves 10 steps at the time.
* Shift Selects the text.

View file

@ -217,7 +217,7 @@ void ttext_box::handle_mouse_selection(tpoint mouse, const bool start_selection)
{
mouse.x -= get_x();
mouse.y -= get_y();
// FIXME we dont test for overflow in width
// FIXME we don't test for overflow in width
if(mouse.x < static_cast<int>(text_x_offset_) ||
mouse.y < static_cast<int>(text_y_offset_) ||
mouse.y >= static_cast<int>(text_y_offset_ + text_height_)) {

View file

@ -83,7 +83,7 @@ public:
* Inherited from tpanel.
*
* @todo only due to the fact our definition is slightly different from
* tpanel_defintion we need to override this function and do about the same,
* tpanel_definition we need to override this function and do about the same,
* look at a way to 'fix' that.
*/
SDL_Rect get_client_rect() const;
@ -92,7 +92,7 @@ public:
* Inherited from tpanel.
*
* @todo only due to the fact our definition is slightly different from
* tpanel_defintion we need to override this function and do about the same,
* tpanel_definition we need to override this function and do about the same,
* look at a way to 'fix' that.
*/
tpoint border_space() const;

View file

@ -160,7 +160,7 @@ public:
/**
* Tries to reduce the width of a widget.
*
* This function does it more agressive and should only be used when
* This function does it more aggressive and should only be used when
* using scrollbars and wrapping failed.
*
* @todo Make pure virtual.
@ -187,7 +187,7 @@ public:
/**
* Tries to reduce the height of a widget.
*
* This function does it more agressive and should only be used when
* This function does it more aggressive and should only be used when
* using scrollbars failed.
*
* @todo Make pure virtual.

View file

@ -1272,7 +1272,7 @@ void twindow::signal_handler_sdl_key_down(
* sized directly, but this is controlled by a window. A widget has an
* internal size cache and if the value in the cache is not equal to 0,0
* that value is its best size. This value gets set when the widget can
* honour a resize request. It will be set with the value which honours
* honour a resize request. It will be set with the value which honors
* the request.
*
* - @ref gui2::tgrid "Grid"; A grid is an invisible container which holds

View file

@ -483,7 +483,7 @@ private:
* Helper struct to force widgets the have the same size.
*
* Widget which are linked will get the same width and/or height. This
* can especialy be usefull for listboxes, but can also be used for other
* can especialy be useful for listboxes, but can also be used for other
* applications.
*/
struct tlinked_size

View file

@ -31,7 +31,7 @@
namespace gui2 {
/**
* Helper to implement private functions without modifing the header.
* Helper to implement private functions without modifying the header.
*
* The class is a helper to avoid recompilation and only has static
* functions.

View file

@ -357,7 +357,7 @@ void unrender(std::set<map_location> invalidated_locations)
size_t halo_count;
// Repeat until set of haloes in the invalidated area didn't change
// (including none found) or all exisiting haloes are found.
// (including none found) or all existing haloes are found.
do {
halo_count = invalidated_haloes.size();
for(itor = haloes.begin(); itor != haloes.end(); ++itor) {

View file

@ -352,7 +352,7 @@ protected:
private:
enum ALIGNMENT {LEFT, MIDDLE, RIGHT, HERE};
/// Convert a string to an alignment. Throw parse_error if
/// unsuccesful.
/// unsuccessful.
ALIGNMENT str_to_align(const std::string &s);
/// An item that is displayed in the text area. Contains the surface

View file

@ -479,8 +479,8 @@ surface locator::load_image_sub_file() const
srcrect.y += surf->h/2 - val_.center_y_;
}
surface cutted(cut_surface(surf, srcrect));
surf = mask_surface(cutted, get_hexmask());
surface cut(cut_surface(surf, srcrect));
surf = mask_surface(cut, get_hexmask());
}
if(val_.modifications_.size()){
@ -1023,7 +1023,7 @@ static TYPE simplify_type(const image::locator& i_locator, TYPE type){
}
if(type == HEXED) {
// check if the image is already hex-cutted by the location system
// check if the image is already hex-cut by the location system
if(i_locator.get_loc().valid())
type = UNSCALED;
}

View file

@ -108,8 +108,8 @@ namespace image {
*
* is_void doesn't seem to work before the image is loaded and also in
* debug mode a placeholder is returned. So it's not possible to test
* for the existance of a file. So this function does that. (Note it
* tests for existance not whether or not it's a valid image.)
* for the existence of a file. So this function does that. (Note it
* tests for existence not whether or not it's a valid image.)
*
* @return Whether or not the file exists.
*/

View file

@ -101,7 +101,7 @@ void loadscreen::draw_screen(const std::string &text)
int scry = screen_.gety() - 2*(bw+bispw);
// Used width.
int pbw = scrx/2;
// Used heigth.
// Used height.
int pbh = scry/16;
// Height of the lighting line.
int lightning_thickness = 2;
@ -117,7 +117,7 @@ void loadscreen::draw_screen(const std::string &text)
}
}
// Draw logo if it was succesfully loaded.
// Draw logo if it was successfully loaded.
if (logo_surface_ && !logo_drawn_) {
area.x = (screen_.getx () - logo_surface_->w) / 2;
area.y = ((scry - logo_surface_->h) / 2) - pbh;

View file

@ -501,7 +501,7 @@ static int costatus (lua_State *L, lua_State *co) {
else
return CO_SUS; /* initial state */
}
default: /* some error occured */
default: /* some error occurred */
return CO_DEAD;
}
}

View file

@ -31,7 +31,7 @@
/* results from luaD_precall */
#define PCRLUA 0 /* initiated a call to a Lua function */
#define PCRC 1 /* did a call to a C function */
#define PCRYIELD 2 /* C funtion yielded */
#define PCRYIELD 2 /* C function yielded */
/* type of protected functions, to be ran by `runprotected' */

View file

@ -390,13 +390,13 @@ static int f_read (lua_State *L) {
static int io_readline (lua_State *L) {
FILE *f = *(FILE **)lua_touserdata(L, lua_upvalueindex(1));
int sucess;
int success;
if (f == NULL) /* file is already closed? */
luaL_error(L, "file is already closed");
sucess = read_line(L, f);
success = read_line(L, f);
if (ferror(f))
return luaL_error(L, "%s", strerror(errno));
if (sucess) return 1;
if (success) return 1;
else { /* EOF */
if (lua_toboolean(L, lua_upvalueindex(2))) { /* generator created file? */
lua_settop(L, 0);

View file

@ -43,7 +43,7 @@ typedef struct stringtable {
/*
** informations about a call
** information about a call
*/
typedef struct CallInfo {
StkId base; /* base for this function */

View file

@ -365,7 +365,7 @@ NO_MALLINFO default: 0
MALLINFO_FIELD_TYPE default: size_t
The type of the fields in the mallinfo struct. This was originally
defined as "int" in SVID etc, but is more usefully defined as
defined as "int" in SVID etc, but is more usefuly defined as
size_t. The value is used only if HAVE_USR_INCLUDE_MALLOC_H is not set
REALLOC_ZERO_BYTES_FREES default: not defined
@ -4160,7 +4160,7 @@ void* dlmalloc(size_t bytes) {
void dlfree(void* mem) {
/*
Consolidate freed chunks with preceeding or succeeding bordering
Consolidate freed chunks with preceding or succeeding bordering
free chunks, if they exist, and then place in a bin. Intermixed
with special cases for top, dv, mmapped chunks, and usage errors.
*/
@ -4997,10 +4997,10 @@ History:
Wolfram Gloger (Gloger@lrz.uni-muenchen.de).
* Use last_remainder in more cases.
* Pack bins using idea from colin@nyx10.cs.du.edu
* Use ordered bins instead of best-fit threshhold
* Use ordered bins instead of best-fit threshold
* Eliminate block-local decls to simplify tracing and debugging.
* Support another case of realloc via move into top
* Fix error occuring when initial sbrk_base not word-aligned.
* Fix error occurring when initial sbrk_base not word-aligned.
* Rely on page size for units instead of SBRK_UNIT to
avoid surprises about sbrk alignment conventions.
* Add mallinfo, mallopt. Thanks to Raymond Nijssen

View file

@ -161,7 +161,7 @@ public:
* Tell if a location is on the map.
*
* Should be called before indexing using [].
* @todo inline for performace? -- Ilor
* @todo inline for performance? -- Ilor
*/
bool on_board(const map_location& loc) const;
bool on_board_with_border(const map_location& loc) const;
@ -265,7 +265,7 @@ private:
/**
* Tries to find out if "terrain" can be created by combining two existing
* terrains Will add the resulting terrain to the terrain list if
* successfull
* successful
*/
bool try_merge_terrains(const t_translation::t_terrain terrain);

View file

@ -85,7 +85,7 @@ struct map_location {
// Location arithmetic operations treating the locations as vectors in
// a hex-based space. These operations form an abelian group, i.e.
// everything works as you would expect addition and substraction to
// everything works as you would expect addition and subtraction to
// work, with associativity and commutativity.
map_location vector_negation() const;
map_location vector_sum(const map_location &a) const;

Some files were not shown because too many files have changed in this diff Show more