summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/formats/mfi_dsk.c2
-rw-r--r--src/lib/util/astring.c24
-rw-r--r--src/lib/util/astring.h6
-rw-r--r--src/lib/util/bitmap.c12
-rw-r--r--src/lib/util/bitmap.h14
-rw-r--r--src/lib/util/zippath.c2
6 files changed, 30 insertions, 30 deletions
diff --git a/src/lib/formats/mfi_dsk.c b/src/lib/formats/mfi_dsk.c
index d756410ef3a..e4849587a17 100644
--- a/src/lib/formats/mfi_dsk.c
+++ b/src/lib/formats/mfi_dsk.c
@@ -53,7 +53,7 @@
preservation formats encode that information, it is guessed for
others. The write track function of fdcs should set it. The
representation is the angular position relative to the index.
-
+
The media type is divided in two parts. The first half
indicate the physical form factor, i.e. all medias with that
form factor can be physically inserted in a reader that handles
diff --git a/src/lib/util/astring.c b/src/lib/util/astring.c
index e890eea884a..2c001f3db62 100644
--- a/src/lib/util/astring.c
+++ b/src/lib/util/astring.c
@@ -143,7 +143,7 @@ astring &astring::init()
astring::~astring()
{
- if (m_text != m_smallbuf)
+ if (m_text != m_smallbuf)
delete[] m_text;
}
@@ -172,7 +172,7 @@ astring &astring::cpy(const char *src, int count)
//-------------------------------------------------
-// cpysubstr - copy a substring of one string to
+// cpysubstr - copy a substring of one string to
// another
//-------------------------------------------------
@@ -208,7 +208,7 @@ astring &astring::ins(int insbefore, const char *src, int count)
//-------------------------------------------------
-// inssubstr - insert a substring of one string
+// inssubstr - insert a substring of one string
// into another
//-------------------------------------------------
@@ -220,7 +220,7 @@ astring &astring::inssubstr(int insbefore, const astring &src, int start, int co
//-------------------------------------------------
-// substr - extract a substring of ourself,
+// substr - extract a substring of ourself,
// removing everything else
//-------------------------------------------------
@@ -242,7 +242,7 @@ astring &astring::substr(int start, int count)
//-------------------------------------------------
-// del - delete a substring of ourself, keeping
+// del - delete a substring of ourself, keeping
// everything else
//-------------------------------------------------
@@ -281,7 +281,7 @@ int astring::vprintf(const char *format, va_list args)
//-------------------------------------------------
-// catprintf - formatted vprintf to the end of
+// catprintf - formatted vprintf to the end of
// an astring
//-------------------------------------------------
@@ -367,7 +367,7 @@ int astring::icmpsubstr(const astring &str2, int start, int count) const
//-------------------------------------------------
-// chr - return the index of a character in an
+// chr - return the index of a character in an
// astring
//-------------------------------------------------
@@ -379,7 +379,7 @@ int astring::chr(int start, int ch) const
//-------------------------------------------------
-// rchr - return the index of a character in an
+// rchr - return the index of a character in an
// astring, searching from the end
//-------------------------------------------------
@@ -402,8 +402,8 @@ int astring::find(int start, const char *search) const
//-------------------------------------------------
-// replacec - search in an astring for a C string,
-// replacing all instances with another C string
+// replacec - search in an astring for a C string,
+// replacing all instances with another C string
// and returning the number of matches
//-------------------------------------------------
@@ -444,7 +444,7 @@ astring &astring::delchr(int ch)
//-------------------------------------------------
-// replacechr - replace all instances of 'ch'
+// replacechr - replace all instances of 'ch'
// with 'newch'
//-------------------------------------------------
@@ -485,7 +485,7 @@ astring &astring::makelower()
//-------------------------------------------------
-// trimspace - remove all space characters from
+// trimspace - remove all space characters from
// beginning/end
//-------------------------------------------------
diff --git a/src/lib/util/astring.h b/src/lib/util/astring.h
index dfac762f065..09236de8f5d 100644
--- a/src/lib/util/astring.h
+++ b/src/lib/util/astring.h
@@ -94,18 +94,18 @@ public:
bool operator>=(const char *string) const { return (cmp(string) >= 0); }
bool operator>=(const astring &string) const { return (cmp(string) >= 0); }
- // character access operators
+ // character access operators
char operator[](int index) const { return (index < len()) ? m_text[index] : 0; }
// implicit boolean conversion operators
operator bool() { return m_text[0] != 0; }
operator bool() const { return m_text[0] != 0; }
-
+
// C string conversion operators and helpers
operator const char *() const { return m_text; }
const char *cstr() const { return m_text; }
char *stringbuffer(int size) { ensure_room(size); return m_text; }
-
+
// buffer management
astring &reset() { return cpy(""); }
astring &expand(int length) { ensure_room(length); return *this; }
diff --git a/src/lib/util/bitmap.c b/src/lib/util/bitmap.c
index f64302e9567..42befb052cb 100644
--- a/src/lib/util/bitmap.c
+++ b/src/lib/util/bitmap.c
@@ -110,7 +110,7 @@ void bitmap_t::allocate(int width, int height, bitmap_format format, int xslop,
{
// delete any existing stuff
deallocate();
-
+
// initialize fields
m_rowpixels = (width + 2 * xslop + 7) & ~7;
m_width = width;
@@ -120,7 +120,7 @@ void bitmap_t::allocate(int width, int height, bitmap_format format, int xslop,
if (m_bpp == 0)
throw std::bad_alloc();
m_cliprect.set(0, width - 1, 0, height - 1);
-
+
// allocate memory for the bitmap itself
size_t allocbytes = m_rowpixels * (m_height + 2 * yslop) * m_bpp / 8;
m_alloc = new UINT8[allocbytes];
@@ -145,7 +145,7 @@ void bitmap_t::deallocate()
delete[] m_alloc;
m_alloc = NULL;
m_base = NULL;
-
+
// reset all fields
m_rowpixels = 0;
m_width = 0;
@@ -157,8 +157,8 @@ void bitmap_t::deallocate()
//-------------------------------------------------
-// clone_existing -- clone an existing bitmap by
-// copying its fields; the target bitmap does not
+// clone_existing -- clone an existing bitmap by
+// copying its fields; the target bitmap does not
// own the memory
//-------------------------------------------------
@@ -181,7 +181,7 @@ void bitmap_t::clone_existing(const bitmap_t &srcbitmap)
//-------------------------------------------------
-// set_palette -- associate a palette with a
+// set_palette -- associate a palette with a
// bitmap
//-------------------------------------------------
diff --git a/src/lib/util/bitmap.h b/src/lib/util/bitmap.h
index 969e34f8e40..98ff5c6e133 100644
--- a/src/lib/util/bitmap.h
+++ b/src/lib/util/bitmap.h
@@ -94,13 +94,13 @@ public:
if (src.max_y > max_y) max_y = src.max_y;
return *this;
}
-
+
// other helpers
bool empty() const { return (min_x > max_x || min_y > max_y); }
bool contains(INT32 x, INT32 y) const { return (x >= min_x && x <= max_x && y >= min_y && y <= max_y); }
INT32 width() const { return max_x + 1 - min_x; }
INT32 height() const { return max_y + 1 - min_y; }
-
+
// setters
void set(INT32 minx, INT32 maxx, INT32 miny, INT32 maxy) { min_x = minx; max_x = maxx; min_y = miny; max_y = maxy; }
void set_width(INT32 width) { max_x = min_x + width - 1; }
@@ -129,7 +129,7 @@ public:
bitmap_t(int width, int height, bitmap_format format, int xslop = 0, int yslop = 0);
bitmap_t(void *base, int width, int height, int rowpixels, bitmap_format format);
~bitmap_t();
-
+
// getters
INT32 width() const { return m_width; }
INT32 height() const { return m_height; }
@@ -140,7 +140,7 @@ public:
bool valid() const { return (m_format != BITMAP_FORMAT_INVALID); }
palette_t *palette() const { return m_palette; }
const rectangle &cliprect() const { return m_cliprect; }
-
+
// operations
void allocate(int width, int height, bitmap_format format, int xslop = 0, int yslop = 0);
void deallocate();
@@ -153,7 +153,7 @@ public:
rectangle clip(x, x + width - 1, y, y + height - 1);
fill(color, clip);
}
-
+
// pixel access
template<typename _PixelType>
_PixelType &pix(INT32 y, INT32 x = 0) const { return *(reinterpret_cast<_PixelType *>(m_base) + y * m_rowpixels + x); }
@@ -162,7 +162,7 @@ public:
UINT32 &pix32(INT32 y, INT32 x = 0) const { return *(reinterpret_cast<UINT32 *>(m_base) + y * m_rowpixels + x); }
UINT64 &pix64(INT32 y, INT32 x = 0) const { return *(reinterpret_cast<UINT64 *>(m_base) + y * m_rowpixels + x); }
void *raw_pixptr(INT32 y, INT32 x = 0) const { return reinterpret_cast<UINT8 *>(m_base) + (y * m_rowpixels + x) * m_bpp / 8; }
-
+
// static helpers
static UINT8 format_to_bpp(bitmap_format format);
@@ -171,7 +171,7 @@ private:
UINT8 * m_alloc; // pointer to allocated pixel memory
void * m_base; // pointer to pixel (0,0) (adjusted for padding)
INT32 m_rowpixels; // pixels per row (including padding)
- INT32 m_width; // width of the bitmap
+ INT32 m_width; // width of the bitmap
INT32 m_height; // height of the bitmap
bitmap_format m_format; // format of the bitmap
UINT8 m_bpp; // bits per pixel
diff --git a/src/lib/util/zippath.c b/src/lib/util/zippath.c
index 1974fe973ee..3f7d62ba2c3 100644
--- a/src/lib/util/zippath.c
+++ b/src/lib/util/zippath.c
@@ -522,7 +522,7 @@ static file_error zippath_resolve(const char *path, osd_dir_entry_type &entry_ty
osd_dir_entry_type current_entry_type;
int went_up = FALSE;
int i;
-
+
newpath.reset();
/* be conservative */