From: Dana Jansens Date: Sat, 16 Nov 2002 13:00:22 +0000 (+0000) Subject: add OtkFocusLabel X-Git-Url: https://git.brokenzipper.com/gitweb?a=commitdiff_plain;h=6b977b2ded0b8807dd05bb7ee0c318612600027d;p=chaz%2Fopenbox add OtkFocusLabel --- diff --git a/otk/Makefile.am b/otk/Makefile.am index 6f363b25..8637f46a 100644 --- a/otk/Makefile.am +++ b/otk/Makefile.am @@ -4,11 +4,12 @@ INCLUDES= -I../src noinst_LIBRARIES=libotk.a -libotk_a_SOURCES= color.cc display.cc font.cc gccache.cc image.cc property.cc \ - imagecontrol.cc rect.cc screeninfo.cc texture.cc timer.cc \ - timerqueuemanager.cc style.cc configuration.cc util.cc \ - widget.cc focuswidget.cc button.cc eventhandler.cc \ - eventdispatcher.cc application.cc +libotk_a_SOURCES= color.cc display.cc font.cc gccache.cc image.cc \ + property.cc imagecontrol.cc rect.cc screeninfo.cc \ + texture.cc timer.cc timerqueuemanager.cc style.cc \ + configuration.cc util.cc widget.cc focuswidget.cc \ + button.cc eventhandler.cc eventdispatcher.cc \ + focuslabel.cc application.cc MAINTAINERCLEANFILES= Makefile.in diff --git a/otk/style.cc b/otk/style.cc index 3c40e24b..277924d6 100644 --- a/otk/style.cc +++ b/otk/style.cc @@ -156,32 +156,6 @@ void Style::load(const Configuration &style) { } -void Style::doJustify(const std::string &text, int &start_pos, - unsigned int max_length, - unsigned int modifier) const { - size_t text_len = text.size(); - unsigned int length; - - do { - length = font->measureString(std::string(text, 0, text_len)) + modifier; - } while (length > max_length && text_len-- > 0); - - switch (justify) { - case RightJustify: - start_pos += max_length - length; - break; - - case CenterJustify: - start_pos += (max_length - length) / 2; - break; - - case LeftJustify: - default: - break; - } -} - - void Style::readDatabaseMask(const std::string &rname, PixmapMask &pixmapMask, const Configuration &style) { Window root_window = OBDisplay::screenInfo(screen_number)->getRootWindow(); diff --git a/otk/style.hh b/otk/style.hh index ccf4e49a..c024ade9 100644 --- a/otk/style.hh +++ b/otk/style.hh @@ -65,9 +65,6 @@ public: Style(BImageControl *); ~Style(); - void doJustify(const std::string &text, int &start_pos, - unsigned int max_length, unsigned int modifier) const; - void readDatabaseMask(const std::string &rname, PixmapMask &pixmapMask, const Configuration &style);