diff options
24 files changed, 42 insertions, 42 deletions
diff --git a/components/compositing/constellation.rs b/components/compositing/constellation.rs index a993394de13..44f26e97565 100644 --- a/components/compositing/constellation.rs +++ b/components/compositing/constellation.rs @@ -773,7 +773,7 @@ impl<LTF: LayoutTaskFactory, STF: ScriptTaskFactory> Constellation<LTF, STF> { } } // Being here means either there are no pending frames, or none of the pending - // changes would be overriden by changing the subframe associated with source_id. + // changes would be overridden by changing the subframe associated with source_id. let parent = source_frame.parent.clone(); let subpage_id = source_frame.pipeline.subpage_id; diff --git a/components/gfx/font_cache_task.rs b/components/gfx/font_cache_task.rs index 1b56a5994a3..3af5bd0d8d4 100644 --- a/components/gfx/font_cache_task.rs +++ b/components/gfx/font_cache_task.rs @@ -30,7 +30,7 @@ impl FontFamily { } } - /// Find a font in this family that matches a given desriptor. + /// Find a font in this family that matches a given descriptor. fn find_font_for_style<'a>(&'a mut self, desc: &FontTemplateDescriptor, fctx: &FontContextHandle) -> Option<Arc<FontTemplateData>> { // TODO(Issue #189): optimize lookup for diff --git a/components/gfx/platform/freetype/font.rs b/components/gfx/platform/freetype/font.rs index 475f0eeddb9..90179b377a3 100644 --- a/components/gfx/platform/freetype/font.rs +++ b/components/gfx/platform/freetype/font.rs @@ -213,11 +213,11 @@ impl FontHandleMethods for FontHandle { let max_advance = self.font_units_to_au(face.max_advance_width as f64); // 'leading' is supposed to be the vertical distance between two baselines, - // reflected by the height attibute in freetype. On OS X (w/ CTFont), + // reflected by the height attribute in freetype. On OS X (w/ CTFont), // leading represents the distance between the bottom of a line descent to // the top of the next line's ascent or: (line_height - ascent - descent), // see http://stackoverflow.com/a/5635981 for CTFont implementation. - // Convert using a formular similar to what CTFont returns for consistency. + // Convert using a formula similar to what CTFont returns for consistency. let height = self.font_units_to_au(face.height as f64); let leading = height - (ascent + descent); diff --git a/components/gfx/text/glyph.rs b/components/gfx/text/glyph.rs index 4d68bf89049..c1d601b8120 100644 --- a/components/gfx/text/glyph.rs +++ b/components/gfx/text/glyph.rs @@ -387,7 +387,7 @@ impl<'a> DetailedGlyphStore { return; } - // Sorting a unique vector is surprisingly hard. The follwing + // Sorting a unique vector is surprisingly hard. The following // code is a good argument for using DVecs, but they require // immutable locations thus don't play well with freezing. diff --git a/components/gfx/text/shaping/harfbuzz.rs b/components/gfx/text/shaping/harfbuzz.rs index 4133bad9cfa..23c39a195ca 100644 --- a/components/gfx/text/shaping/harfbuzz.rs +++ b/components/gfx/text/shaping/harfbuzz.rs @@ -156,7 +156,7 @@ impl Drop for Shaper { impl Shaper { pub fn new(font: &mut Font) -> Shaper { unsafe { - // Indirection for Rust Issue #6248, dynamic freeze scope artifically extended + // Indirection for Rust Issue #6248, dynamic freeze scope artificially extended let font_ptr = font as *mut Font; let hb_face: *mut hb_face_t = hb_face_create_for_tables(get_font_table_func, font_ptr as *mut c_void, @@ -282,7 +282,7 @@ impl Shaper { let mut y_pos = Au(0); // main loop over each glyph. each iteration usually processes 1 glyph and 1+ chars. - // in cases with complex glyph-character assocations, 2+ glyphs and 1+ chars can be + // in cases with complex glyph-character associations, 2+ glyphs and 1+ chars can be // processed. while glyph_span.begin() < glyph_count { // start by looking at just one glyph. diff --git a/components/layout/floats.rs b/components/layout/floats.rs index aba36dad080..887ff67446d 100644 --- a/components/layout/floats.rs +++ b/components/layout/floats.rs @@ -237,7 +237,7 @@ impl Floats { // FIXME(eatkinson): This assertion is too strong and fails in some cases. It is OK to // return negative inline-sizes since we check against that inline-end away, but we should - // still undersrtand why they occur and add a stronger assertion here. + // still understand why they occur and add a stronger assertion here. // assert!(max_inline-start < min_inline-end); assert!(block_start <= block_end, "Float position error"); diff --git a/components/layout/inline.rs b/components/layout/inline.rs index eb069c755bc..ef704a453ac 100644 --- a/components/layout/inline.rs +++ b/components/layout/inline.rs @@ -128,7 +128,7 @@ pub struct Line { /// ~~~ pub bounds: LogicalRect<Au>, - /// The green zone is the greatest extent from wich a line can extend to + /// The green zone is the greatest extent from which a line can extend to /// before it collides with a float. /// /// ~~~text @@ -307,7 +307,7 @@ impl LineBreaker { let splittable = first_fragment.can_split(); debug!("LineBreaker: fragment size: {}, splittable: {}", first_fragment_size, splittable); - // Initally, pretend a splittable fragment has zero inline-size. We will move it later if + // Initially, pretend a splittable fragment has zero inline-size. We will move it later if // it has nonzero inline-size and that causes problems. let placement_inline_size = if splittable { Au(0) diff --git a/components/layout/text.rs b/components/layout/text.rs index 757d7cb18bf..c12119f4510 100644 --- a/components/layout/text.rs +++ b/components/layout/text.rs @@ -250,7 +250,7 @@ fn bounding_box_for_run_metrics(metrics: &RunMetrics, writing_mode: WritingMode) None => {} } - // In vertical sideways or horizontal upgright text, + // In vertical sideways or horizontal upright text, // the "width" of text metrics is always inline // This will need to be updated when other text orientations are supported. LogicalSize::new( diff --git a/components/net/image_cache_task.rs b/components/net/image_cache_task.rs index d2fa908e47c..663842adb5e 100644 --- a/components/net/image_cache_task.rs +++ b/components/net/image_cache_task.rs @@ -138,7 +138,7 @@ struct ImageCache { port: Receiver<Msg>, /// A copy of the shared chan to give to child tasks chan: Sender<Msg>, - /// The state of processsing an image for a URL + /// The state of processing an image for a URL state_map: HashMap<Url, ImageState>, /// List of clients waiting on a WaitForImage response wait_map: HashMap<Url, Arc<Mutex<Vec<Sender<ImageResponseMsg>>>>>, diff --git a/components/net/local_image_cache.rs b/components/net/local_image_cache.rs index 0227f7fe91f..089f7c6b237 100644 --- a/components/net/local_image_cache.rs +++ b/components/net/local_image_cache.rs @@ -124,7 +124,7 @@ impl<NodeAddress: Send> LocalImageCache<NodeAddress> { // Need to reflow when the image is available // FIXME: Instead we should be just passing a Future // to the caller, then to the display list. Finally, - // the compositor should be resonsible for waiting + // the compositor should be responsible for waiting // on the image to load and triggering layout let image_cache_task = self.image_cache_task.clone(); assert!(self.on_image_available.is_some()); diff --git a/components/script/cors.rs b/components/script/cors.rs index abd99af36d2..4b217508978 100644 --- a/components/script/cors.rs +++ b/components/script/cors.rs @@ -56,7 +56,7 @@ impl CORSRequest { return Ok(None); // Not cross-origin, proceed with a normal fetch } match destination.scheme.as_slice() { - // Todo: If the request's same origin data url flag is set (which isn't the case for XHR) + // TODO: If the request's same origin data url flag is set (which isn't the case for XHR) // we can fetch a data URL normally. about:blank can also be fetched by XHR "http" | "https" => { let mut req = CORSRequest::new(referer, destination, mode, method, headers); diff --git a/components/script/dom/bindings/codegen/test/TestCodeGen.webidl b/components/script/dom/bindings/codegen/test/TestCodeGen.webidl index 8c2b3c1b6b4..67c5fdf946b 100644 --- a/components/script/dom/bindings/codegen/test/TestCodeGen.webidl +++ b/components/script/dom/bindings/codegen/test/TestCodeGen.webidl @@ -105,7 +105,7 @@ interface TestInterface { TestInterface? receiveNullableSelf(); TestInterface receiveWeakSelf(); TestInterface? receiveWeakNullableSelf(); - // A verstion to test for casting to TestInterface& + // A version to test for casting to TestInterface& void passSelf(TestInterface arg); // A version we can use to test for the exact type passed in void passSelf2(TestInterface arg); @@ -136,7 +136,7 @@ interface TestInterface { TestNonCastableInterface? receiveNullableOther(); TestNonCastableInterface receiveWeakOther(); TestNonCastableInterface? receiveWeakNullableOther(); - // A verstion to test for casting to TestNonCastableInterface& + // A version to test for casting to TestNonCastableInterface& void passOther(TestNonCastableInterface arg); // A version we can use to test for the exact type passed in void passOther2(TestNonCastableInterface arg); @@ -153,7 +153,7 @@ interface TestInterface { TestExternalInterface? receiveNullableExternal(); TestExternalInterface receiveWeakExternal(); TestExternalInterface? receiveWeakNullableExternal(); - // A verstion to test for casting to TestExternalInterface& + // A version to test for casting to TestExternalInterface& void passExternal(TestExternalInterface arg); // A version we can use to test for the exact type passed in void passExternal2(TestExternalInterface arg); @@ -170,7 +170,7 @@ interface TestInterface { TestCallbackInterface? receiveNullableCallbackInterface(); TestCallbackInterface receiveWeakCallbackInterface(); TestCallbackInterface? receiveWeakNullableCallbackInterface(); - // A verstion to test for casting to TestCallbackInterface& + // A version to test for casting to TestCallbackInterface& void passCallbackInterface(TestCallbackInterface arg); // A version we can use to test for the exact type passed in void passCallbackInterface2(TestCallbackInterface arg); diff --git a/components/script/dom/xmlhttprequest.rs b/components/script/dom/xmlhttprequest.rs index 530b262a75f..0f8e770d8d5 100644 --- a/components/script/dom/xmlhttprequest.rs +++ b/components/script/dom/xmlhttprequest.rs @@ -252,7 +252,7 @@ impl XMLHttpRequest { let (chan, cors_port) = channel(); let req2 = req.clone(); // TODO: this exists only to make preflight check non-blocking - // perhaps shoud be handled by the resource_loader? + // perhaps should be handled by the resource_loader? spawn_named("XHR:Cors", proc() { let response = req2.http_fetch(); chan.send(response); diff --git a/components/style/media_queries.rs b/components/style/media_queries.rs index 30879d64f4b..33d5203064e 100644 --- a/components/style/media_queries.rs +++ b/components/style/media_queries.rs @@ -262,7 +262,7 @@ pub fn parse_media_query_list(input: &[ComponentValue]) -> MediaQueryList { } // Add the media query if it was valid and no trailing tokens were found. - // Otherwse, create a 'not all' media query, that will never match. + // Otherwise, create a 'not all' media query, that will never match. let media_query = match (media_query_result, trailing_tokens) { (Ok(media_query), false) => media_query, _ => MediaQuery::new(Some(Not), All, vec!()), diff --git a/components/style/selector_matching.rs b/components/style/selector_matching.rs index 51850e08a27..7cd1fd1d232 100644 --- a/components/style/selector_matching.rs +++ b/components/style/selector_matching.rs @@ -663,7 +663,7 @@ fn matches_compound_selector<'a,E,N>(selector: &CompoundSelector, /// candidates for "d1" becomes less than before and d1 . /// /// The next example is siblings. When the selector "b1 + b2 ~ d1 a" is -/// providied and we cannot *find* an appropriate brother node for b1, +/// provided and we cannot *find* an appropriate brother node for b1, /// the selector matching raises NotMatchedAndRestartFromClosestDescendant. /// The selectors ("b1 + b2 ~") doesn't match and matching restart from "d1". /// diff --git a/components/style/stylesheets.rs b/components/style/stylesheets.rs index a1ae75520af..efec013ee2d 100644 --- a/components/style/stylesheets.rs +++ b/components/style/stylesheets.rs @@ -46,7 +46,7 @@ impl Stylesheet { mut input: I, base_url: Url, protocol_encoding_label: Option<&str>, environment_encoding: Option<EncodingRef>, origin: StylesheetOrigin) -> Stylesheet { let mut bytes = vec!(); - // TODO: incremental decoding and tokinization/parsing + // TODO: incremental decoding and tokenization/parsing for chunk in input { bytes.push_all(chunk.as_slice()) } diff --git a/components/util/logical_geometry.rs b/components/util/logical_geometry.rs index 06912ed8c39..96664cc5605 100644 --- a/components/util/logical_geometry.rs +++ b/components/util/logical_geometry.rs @@ -25,13 +25,13 @@ impl WritingMode { self.intersects(FLAG_VERTICAL) } - /// Asuming .is_vertical(), does the block direction go left to right? + /// Assuming .is_vertical(), does the block direction go left to right? #[inline] pub fn is_vertical_lr(&self) -> bool { self.intersects(FLAG_VERTICAL_LR) } - /// Asuming .is_vertical(), does the inline direction go top to bottom? + /// Assuming .is_vertical(), does the inline direction go top to bottom? #[inline] pub fn is_inline_tb(&self) -> bool { !(self.intersects(FLAG_SIDEWAYS_LEFT) ^ self.intersects(FLAG_RTL)) @@ -403,7 +403,7 @@ impl<T: Copy + Sub<T, T>> LogicalPoint<T> { impl<T: Add<T,T>> LogicalPoint<T> { /// This doesn’t really makes sense, - /// but happens when dealing with mutliple origins. + /// but happens when dealing with multiple origins. #[inline] pub fn add_point(&self, other: &LogicalPoint<T>) -> LogicalPoint<T> { self.debug_writing_mode.check_debug(other.debug_writing_mode); diff --git a/ports/cef/interfaces/cef_browser.rs b/ports/cef/interfaces/cef_browser.rs index 47c49466e2a..6d0ec4eac3d 100644 --- a/ports/cef/interfaces/cef_browser.rs +++ b/ports/cef/interfaces/cef_browser.rs @@ -864,7 +864,7 @@ pub struct _cef_browser_host_t { // // Search for |searchText|. |identifier| can be used to have multiple searches - // running simultaniously. |forward| indicates whether to search forward or + // running simultaneously. |forward| indicates whether to search forward or // backward within the page. |matchCase| indicates whether the search should // be case-sensitive. |findNext| indicates whether this is the first request // or a follow-up. @@ -1089,7 +1089,7 @@ pub struct _cef_browser_host_t { // being cancelled. |x| and |y| are mouse coordinates relative to the upper- // left corner of the view. If the web view is both the drag source and the // drag target then all DragTarget* functions should be called before - // DragSource* mthods. This function is only used when window rendering is + // DragSource* methods. This function is only used when window rendering is // disabled. // pub drag_source_ended_at: Option<extern "C" fn(this: *mut cef_browser_host_t, @@ -1101,7 +1101,7 @@ pub struct _cef_browser_host_t { // cef_render_handler_t::StartDragging call has completed. This function may // be called immediately without first calling DragSourceEndedAt to cancel a // drag operation. If the web view is both the drag source and the drag target - // then all DragTarget* functions should be called before DragSource* mthods. + // then all DragTarget* functions should be called before DragSource* methods. // This function is only used when window rendering is disabled. // pub drag_source_system_drag_ended: Option<extern "C" fn( @@ -1416,7 +1416,7 @@ impl CefBrowserHost { // // Search for |searchText|. |identifier| can be used to have multiple searches - // running simultaniously. |forward| indicates whether to search forward or + // running simultaneously. |forward| indicates whether to search forward or // backward within the page. |matchCase| indicates whether the search should // be case-sensitive. |findNext| indicates whether this is the first request // or a follow-up. @@ -1888,7 +1888,7 @@ impl CefBrowserHost { // being cancelled. |x| and |y| are mouse coordinates relative to the upper- // left corner of the view. If the web view is both the drag source and the // drag target then all DragTarget* functions should be called before - // DragSource* mthods. This function is only used when window rendering is + // DragSource* methods. This function is only used when window rendering is // disabled. // pub fn drag_source_ended_at(&self, x: libc::c_int, y: libc::c_int, @@ -1911,7 +1911,7 @@ impl CefBrowserHost { // cef_render_handler_t::StartDragging call has completed. This function may // be called immediately without first calling DragSourceEndedAt to cancel a // drag operation. If the web view is both the drag source and the drag target - // then all DragTarget* functions should be called before DragSource* mthods. + // then all DragTarget* functions should be called before DragSource* methods. // This function is only used when window rendering is disabled. // pub fn drag_source_system_drag_ended(&self) -> () { diff --git a/ports/cef/interfaces/cef_context_menu_handler.rs b/ports/cef/interfaces/cef_context_menu_handler.rs index 8dac9e5ebf8..c70bed4e21d 100644 --- a/ports/cef/interfaces/cef_context_menu_handler.rs +++ b/ports/cef/interfaces/cef_context_menu_handler.rs @@ -274,7 +274,7 @@ impl CefWrap<*mut cef_context_menu_handler_t> for Option<CefContextMenuHandler> // -// Provides information about the context menu state. The ethods of this +// Provides information about the context menu state. The methods of this // structure can only be accessed on browser process the UI thread. // #[repr(C)] @@ -438,7 +438,7 @@ pub type cef_context_menu_params_t = _cef_context_menu_params_t; // -// Provides information about the context menu state. The ethods of this +// Provides information about the context menu state. The methods of this // structure can only be accessed on browser process the UI thread. // pub struct CefContextMenuParams { diff --git a/ports/cef/interfaces/cef_life_span_handler.rs b/ports/cef/interfaces/cef_life_span_handler.rs index d218c4bbf15..af9a9856a62 100644 --- a/ports/cef/interfaces/cef_life_span_handler.rs +++ b/ports/cef/interfaces/cef_life_span_handler.rs @@ -95,7 +95,7 @@ pub struct _cef_life_span_handler_t { browser: *mut interfaces::cef_browser_t) -> libc::c_int>, // - // Called when a browser has recieved a request to close. This may result + // Called when a browser has received a request to close. This may result // directly from a call to cef_browser_host_t::close_browser() or indirectly // if the browser is a top-level OS window created by CEF and the user // attempts to close the window. This function will be called after the @@ -318,7 +318,7 @@ impl CefLifeSpanHandler { } // - // Called when a browser has recieved a request to close. This may result + // Called when a browser has received a request to close. This may result // directly from a call to cef_browser_host_t::close_browser() or indirectly // if the browser is a top-level OS window created by CEF and the user // attempts to close the window. This function will be called after the diff --git a/ports/cef/interfaces/cef_v8.rs b/ports/cef/interfaces/cef_v8.rs index 4a42ef8d36c..2672dcd07a1 100644 --- a/ports/cef/interfaces/cef_v8.rs +++ b/ports/cef/interfaces/cef_v8.rs @@ -1168,7 +1168,7 @@ pub struct _cef_v8value_t { pub get_int_value: Option<extern "C" fn(this: *mut cef_v8value_t) -> i32>, // - // Return an unisgned int value. The underlying data will be converted to if + // Return an unsigned int value. The underlying data will be converted to if // necessary. // pub get_uint_value: Option<extern "C" fn(this: *mut cef_v8value_t) -> u32>, @@ -1714,7 +1714,7 @@ impl CefV8Value { } // - // Return an unisgned int value. The underlying data will be converted to if + // Return an unsigned int value. The underlying data will be converted to if // necessary. // pub fn get_uint_value(&self) -> u32 { diff --git a/ports/cef/types.rs b/ports/cef/types.rs index b44f2a84159..09aa60349d5 100644 --- a/ports/cef/types.rs +++ b/ports/cef/types.rs @@ -385,7 +385,7 @@ pub struct cef_key_event { pub windows_key_code: c_int, // - // The actual key code genenerated by the platform. + // The actual key code generated by the platform. // pub native_key_code: c_int, @@ -761,7 +761,7 @@ pub struct cef_settings { // // Opaque background color used for accelerated content. By default the - // background color will be white. Only the RGB compontents of the specified + // background color will be white. Only the RGB components of the specified // value will be used. The alpha component must greater than 0 to enable use // of the background color but will be otherwise ignored. // @@ -1441,7 +1441,7 @@ pub struct _cef_geoposition_t { pub speed: c_double, // - // Time of position measurement in miliseconds since Epoch in UTC time. This + // Time of position measurement in milliseconds since Epoch in UTC time. This // is taken from the host computer's system clock. // pub timestamp: cef_time_t, diff --git a/tests/html/acid2.html b/tests/html/acid2.html index b6432099e4d..9c7712a22f7 100755 --- a/tests/html/acid2.html +++ b/tests/html/acid2.html @@ -19,7 +19,7 @@ /* picture setup */ #top { margin: 100em 3em 0; padding: 2em 0 0 .5em; text-align: left; font: 2em/24px sans-serif; color: navy; white-space: pre; } /* "Hello World!" text */ .picture { position: relative; border: 1em solid transparent; margin: 0 0 100em 3em; } /* containing block for face */ - .picture { background: red; } /* overriden by preferred stylesheet below */ + .picture { background: red; } /* overridden by preferred stylesheet below */ /* top line of face (scalp): fixed positioning and min/max height/width */ .picture p { position: fixed; margin: 0; padding: 0; border: 0; top: 9em; left: 11em; width: 140%; max-width: 4em; height: 8px; min-height: 1em; max-height: 2mm; /* min-height overrides max-height, see 10.7 */ background: black; border-bottom: 0.5em yellow solid; } diff --git a/tests/ref/acid2_noscroll.html b/tests/ref/acid2_noscroll.html index 5c6e6ff1112..9dc184e9ee5 100755 --- a/tests/ref/acid2_noscroll.html +++ b/tests/ref/acid2_noscroll.html @@ -26,7 +26,7 @@ /* picture setup */ #top { margin: 100em 3em 0; padding: 2em 0 0 .5em; text-align: left; font: 2em/24px sans-serif; color: navy; white-space: pre; } /* "Hello World!" text */ .picture { position: relative; border: 1em solid transparent; margin: 0 0 100em 3em; } /* containing block for face */ - .picture { background: red; } /* overriden by preferred stylesheet below */ + .picture { background: red; } /* overridden by preferred stylesheet below */ /* top line of face (scalp): fixed positioning and min/max height/width */ .picture p { position: fixed; margin: 0; padding: 0; border: 0; top: 9em; left: 11em; width: 140%; max-width: 4em; height: 8px; min-height: 1em; max-height: 2mm; /* min-height overrides max-height, see 10.7 */ background: black; border-bottom: 0.5em yellow solid; } |