Rename serialise to serialize Yes, British English is correct, but unfortunately we've lost that battle. Signed-off-by: Daniel Stone <daniel@fooishbar.org>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134
diff --git a/include/xkbcommon/xkbcommon.h b/include/xkbcommon/xkbcommon.h
index 727c5be..70ecb42 100644
--- a/include/xkbcommon/xkbcommon.h
+++ b/include/xkbcommon/xkbcommon.h
@@ -314,7 +314,7 @@ xkb_map_new_from_fd(struct xkb_ctx *ctx,
enum xkb_map_compile_flags flags);
/**
- * Creates an XKB keymap from a full text XKB keymap serialised into one
+ * Creates an XKB keymap from a full text XKB keymap serialized into one
* enormous string.
*/
struct xkb_keymap *
@@ -505,13 +505,13 @@ enum xkb_state_match {
/**
* Updates a state object from a set of explicit masks. This entrypoint is
* really only for window systems and the like, where a master process
- * holds an xkb_state, then serialises it over a wire protocol, and clients
- * then use the serialisation to feed in to their own xkb_state.
+ * holds an xkb_state, then serializes it over a wire protocol, and clients
+ * then use the serialization to feed in to their own xkb_state.
*
* All parameters must always be passed, or the resulting state may be
* incoherent.
*
- * The serialisation is lossy and will not survive round trips; it must only
+ * The serialization is lossy and will not survive round trips; it must only
* be used to feed slave state objects, and must not be used to update the
* master state.
*
@@ -528,7 +528,7 @@ xkb_state_update_mask(struct xkb_state *state,
/**
* The counterpart to xkb_state_update_mask, to be used on the server side
- * of serialisation. Returns a xkb_mod_mask_t representing the given
+ * of serialization. Returns a xkb_mod_mask_t representing the given
* component(s) of the state.
*
* This function should not be used in regular clients; please use the
@@ -537,15 +537,15 @@ xkb_state_update_mask(struct xkb_state *state,
* Can return NULL on failure.
*/
xkb_mod_mask_t
-xkb_state_serialise_mods(struct xkb_state *state,
+xkb_state_serialize_mods(struct xkb_state *state,
enum xkb_state_component component);
/**
- * The group equivalent of xkb_state_serialise_mods: please see its
+ * The group equivalent of xkb_state_serialize_mods: please see its
* documentation.
*/
xkb_group_index_t
-xkb_state_serialise_group(struct xkb_state *state,
+xkb_state_serialize_group(struct xkb_state *state,
enum xkb_state_component component);
/**
diff --git a/src/state.c b/src/state.c
index 5f78a87..63c7f11 100644
--- a/src/state.c
+++ b/src/state.c
@@ -578,7 +578,7 @@ xkb_state_update_key(struct xkb_state *state, xkb_keycode_t key,
/**
* Updates the state from a set of explicit masks as gained from
- * xkb_state_serialise_mods and xkb_state_serialise_groups. As noted in the
+ * xkb_state_serialize_mods and xkb_state_serialize_groups. As noted in the
* documentation for these functions in xkbcommon.h, this round-trip is
* lossy, and should only be used to update a slave state mirroring the
* master, e.g. in a client/server window system.
@@ -619,7 +619,7 @@ xkb_state_update_mask(struct xkb_state *state,
* the same disclaimers as in xkb_state_update_mask.
*/
_X_EXPORT xkb_mod_mask_t
-xkb_state_serialise_mods(struct xkb_state *state,
+xkb_state_serialize_mods(struct xkb_state *state,
enum xkb_state_component type)
{
xkb_mod_mask_t ret = 0;
@@ -642,7 +642,7 @@ xkb_state_serialise_mods(struct xkb_state *state,
* in xkb_state_update_mask.
*/
_X_EXPORT xkb_group_index_t
-xkb_state_serialise_group(struct xkb_state *state,
+xkb_state_serialize_group(struct xkb_state *state,
enum xkb_state_component type)
{
xkb_group_index_t ret = 0;
@@ -692,7 +692,7 @@ static int
match_mod_masks(struct xkb_state *state, enum xkb_state_match match,
uint32_t wanted)
{
- uint32_t active = xkb_state_serialise_mods(state, XKB_STATE_EFFECTIVE);
+ uint32_t active = xkb_state_serialize_mods(state, XKB_STATE_EFFECTIVE);
if (!(match & XKB_STATE_MATCH_NON_EXCLUSIVE) && (active & ~wanted))
return 0;
diff --git a/test/state.c b/test/state.c
index a147aea..c16518c 100644
--- a/test/state.c
+++ b/test/state.c
@@ -192,23 +192,23 @@ test_serialisation(struct xkb_keymap *keymap)
xkb_state_update_key(state, KEY_CAPSLOCK + EVDEV_OFFSET, XKB_KEY_DOWN);
xkb_state_update_key(state, KEY_CAPSLOCK + EVDEV_OFFSET, XKB_KEY_UP);
- base_mods = xkb_state_serialise_mods(state, XKB_STATE_DEPRESSED);
+ base_mods = xkb_state_serialize_mods(state, XKB_STATE_DEPRESSED);
assert(base_mods == 0);
- latched_mods = xkb_state_serialise_mods(state, XKB_STATE_LATCHED);
+ latched_mods = xkb_state_serialize_mods(state, XKB_STATE_LATCHED);
assert(latched_mods == 0);
- locked_mods = xkb_state_serialise_mods(state, XKB_STATE_LOCKED);
+ locked_mods = xkb_state_serialize_mods(state, XKB_STATE_LOCKED);
assert(locked_mods == (1 << caps));
- effective_mods = xkb_state_serialise_mods(state, XKB_STATE_EFFECTIVE);
+ effective_mods = xkb_state_serialize_mods(state, XKB_STATE_EFFECTIVE);
assert(effective_mods == locked_mods);
xkb_state_update_key(state, KEY_LEFTSHIFT + EVDEV_OFFSET, XKB_KEY_DOWN);
- base_mods = xkb_state_serialise_mods(state, XKB_STATE_DEPRESSED);
+ base_mods = xkb_state_serialize_mods(state, XKB_STATE_DEPRESSED);
assert(base_mods == (1 << shift));
- latched_mods = xkb_state_serialise_mods(state, XKB_STATE_LATCHED);
+ latched_mods = xkb_state_serialize_mods(state, XKB_STATE_LATCHED);
assert(latched_mods == 0);
- locked_mods = xkb_state_serialise_mods(state, XKB_STATE_LOCKED);
+ locked_mods = xkb_state_serialize_mods(state, XKB_STATE_LOCKED);
assert(locked_mods == (1 << caps));
- effective_mods = xkb_state_serialise_mods(state, XKB_STATE_EFFECTIVE);
+ effective_mods = xkb_state_serialize_mods(state, XKB_STATE_EFFECTIVE);
assert(effective_mods == (base_mods | locked_mods));
base_mods |= (1 << ctrl);