Remove dependency on NO_LAYOUT_CSS #define in Layout.cpp

Remove all traces of this #define.
This commit is contained in:
Jean-Marc Lasgouttes 2013-08-21 12:45:00 +02:00 committed by Vincent van Ravesteijn
parent fa5519d4f0
commit 72c13323d8
7 changed files with 19 additions and 7 deletions

View File

@ -1505,14 +1505,11 @@ void Layout::makeDefaultCSS() const
htmldefaultstyle_ += from_ascii(tmp);
}
// tex2lyx does not see output_xhtml.cpp
#ifndef NO_LAYOUT_CSS
// alignment
string where = alignmentToCSS(align);
if (!where.empty()) {
htmldefaultstyle_ += from_ascii("text-align: " + where + ";\n");
}
#endif
// wrap up what we have, if anything
if (!htmldefaultstyle_.empty())

View File

@ -689,7 +689,7 @@ if INSTALL_MACOSX
ADD_FRAMEWORKS = -framework QtGui -framework QtCore -framework AppKit -framework ApplicationServices
endif
check_layout_CPPFLAGS = $(AM_CPPFLAGS) -DNO_LAYOUT_CSS
check_layout_CPPFLAGS = $(AM_CPPFLAGS)
check_layout_LDADD = support/liblyxsupport.a $(LIBICONV) $(BOOST_LIBS) @LIBS@ $(QT4_CORE_LIBS) $(LIBSHLWAPI)
check_layout_LDFLAGS = $(QT4_CORE_LDFLAGS) $(ADD_FRAMEWORKS)
check_layout_SOURCES = \

View File

@ -8,6 +8,11 @@ namespace lyx {
// Dummy LyXRC support
class LyXRC { string icon_set; } lyxrc;
// Dummy LyXAlignment support
enum LyXAlignment {
DUMMY
};
// Keep the linker happy on Windows
void lyx_exit(int) {}
@ -24,4 +29,10 @@ namespace lyx {
return lyx_messages;
}
string alignmentToCSS(LyXAlignment)
{
return string();
}
}

View File

@ -12,7 +12,6 @@ foreach(_f insets/InsetLayout.cpp Color.cpp Counters.cpp Floating.cpp
list(APPEND check_layout_SOURCES "${TOP_SRC_DIR}/src/${_f}")
endforeach()
add_definitions(-DNO_LAYOUT_CSS)
add_executable(check_layout ${check_layout_SOURCES})
target_link_libraries(check_layout support

View File

@ -30,7 +30,6 @@ include_directories(BEFORE
${ZLIB_INCLUDE_DIR})
add_definitions(-DTEX2LYX)
add_definitions(-DNO_LAYOUT_CSS)
if(WIN32)
set(FILE_RC ${TOP_CMAKE_PATH}/lyx.rc)

View File

@ -16,7 +16,7 @@ bin_PROGRAMS = tex2lyx
DEFAULT_INCLUDES =
AM_CPPFLAGS += -DTEX2LYX -DNO_LAYOUT_CSS $(PCH_FLAGS) -I$(top_srcdir)/src/tex2lyx \
AM_CPPFLAGS += -DTEX2LYX $(PCH_FLAGS) -I$(top_srcdir)/src/tex2lyx \
-I$(top_srcdir)/src -I$(top_builddir) $(BOOST_INCLUDES)
TEST_FILES = \

View File

@ -21,6 +21,7 @@
#include "Format.h"
#include "LaTeXFeatures.h"
#include "LyXRC.h"
#include "output_xhtml.h"
#include "support/Messages.h"
@ -115,6 +116,11 @@ bool LaTeXFeatures::isAvailable(string const &)
}
string alignmentToCSS(LyXAlignment)
{
return string();
}
//
// Keep the linker happy on Windows
//