added support for definition lists (DL,DT,DD) to wxHTML
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5031 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
8b260fbe33
commit
336e2d4424
11
Makefile.in
11
Makefile.in
@ -1,5 +1,5 @@
|
||||
#
|
||||
# This file was automatically generated by tmake at 19:00, 1999/12/14
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE UNX.T!
|
||||
|
||||
#
|
||||
@ -248,8 +248,15 @@ WX_HEADERS = \
|
||||
helpwin.h \
|
||||
helpxlp.h \
|
||||
icon.h \
|
||||
imagbmp.h \
|
||||
image.h \
|
||||
imaggif.h \
|
||||
imagjpeg.h \
|
||||
imaglist.h \
|
||||
imagpcx.h \
|
||||
imagpng.h \
|
||||
imagpnm.h \
|
||||
imagtiff.h \
|
||||
intl.h \
|
||||
ioswrap.h \
|
||||
ipcbase.h \
|
||||
@ -1912,6 +1919,7 @@ HTMLOBJS = \
|
||||
htmltag.o \
|
||||
htmlwin.o \
|
||||
htmprint.o \
|
||||
m_dflist.o \
|
||||
m_fonts.o \
|
||||
m_hline.o \
|
||||
m_image.o \
|
||||
@ -1932,6 +1940,7 @@ HTMLDEPS = \
|
||||
htmltag.d \
|
||||
htmlwin.d \
|
||||
htmprint.d \
|
||||
m_dflist.d \
|
||||
m_fonts.d \
|
||||
m_hline.d \
|
||||
m_image.d \
|
||||
|
@ -427,6 +427,7 @@ m_image.cpp H
|
||||
m_layout.cpp H
|
||||
m_links.cpp H
|
||||
m_list.cpp H
|
||||
m_dflist.cpp H
|
||||
m_pre.cpp H
|
||||
m_tables.cpp H
|
||||
htmprint.cpp H
|
||||
|
93
src/html/m_dflist.cpp
Normal file
93
src/html/m_dflist.cpp
Normal file
@ -0,0 +1,93 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: m_dflist.cpp
|
||||
// Purpose: wxHtml module for definition lists (DL,DT,DD)
|
||||
// Author: Vaclav Slavik
|
||||
// RCS-ID: $Id$
|
||||
// Copyright: (c) 1999 Vaclav Slavik
|
||||
// Licence: wxWindows Licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifdef __GNUG__
|
||||
#pragma implementation
|
||||
#endif
|
||||
|
||||
#include "wx/wxprec.h"
|
||||
|
||||
|
||||
#include "wx/defs.h"
|
||||
#if wxUSE_HTML
|
||||
|
||||
#ifdef __BORDLANDC__
|
||||
#pragma hdrstop
|
||||
#endif
|
||||
|
||||
#ifndef WXPRECOMP
|
||||
#include "wx/wx.h"
|
||||
#endif
|
||||
|
||||
|
||||
#include "wx/html/forcelnk.h"
|
||||
#include "wx/html/m_templ.h"
|
||||
|
||||
#include "wx/html/htmlcell.h"
|
||||
|
||||
FORCE_LINK_ME(m_dflist)
|
||||
|
||||
|
||||
|
||||
|
||||
TAG_HANDLER_BEGIN(DEFLIST, "DL,DT,DD")
|
||||
|
||||
TAG_HANDLER_PROC(tag)
|
||||
{
|
||||
wxHtmlContainerCell *c;
|
||||
|
||||
|
||||
if (tag.GetName() == "DL") {
|
||||
if (m_WParser -> GetContainer() -> GetFirstCell() != NULL) {
|
||||
m_WParser -> CloseContainer();
|
||||
m_WParser -> OpenContainer();
|
||||
}
|
||||
m_WParser -> GetContainer() -> SetIndent(m_WParser -> GetCharHeight(), wxHTML_INDENT_TOP);
|
||||
|
||||
ParseInner(tag);
|
||||
|
||||
if (m_WParser -> GetContainer() -> GetFirstCell() != NULL) {
|
||||
m_WParser -> CloseContainer();
|
||||
m_WParser -> OpenContainer();
|
||||
}
|
||||
m_WParser -> GetContainer() -> SetIndent(m_WParser -> GetCharHeight(), wxHTML_INDENT_TOP);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
else if (tag.GetName() == "DT") {
|
||||
if (!tag.IsEnding()) {
|
||||
m_WParser -> CloseContainer();
|
||||
c = m_WParser -> OpenContainer();
|
||||
c -> SetAlignHor(wxHTML_ALIGN_LEFT);
|
||||
c -> SetMinHeight(m_WParser -> GetCharHeight());
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
else if (!tag.IsEnding()) { // "DD"
|
||||
m_WParser -> CloseContainer();
|
||||
c = m_WParser -> OpenContainer();
|
||||
c -> SetIndent(5 * m_WParser -> GetCharWidth(), wxHTML_INDENT_LEFT);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
else return FALSE;
|
||||
}
|
||||
|
||||
TAG_HANDLER_END(DEFLIST)
|
||||
|
||||
|
||||
TAGS_MODULE_BEGIN(DefinitionList)
|
||||
|
||||
TAGS_MODULE_ADD(DEFLIST)
|
||||
|
||||
TAGS_MODULE_END(DefinitionList)
|
||||
|
||||
#endif
|
@ -1,6 +1,6 @@
|
||||
|
||||
|
||||
# This file was automatically generated by tmake at 23:50, 1999/12/15
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE B32.T!
|
||||
|
||||
#
|
||||
@ -313,6 +313,7 @@ HTMLOBJS = $(MSWDIR)\helpctrl.obj \
|
||||
$(MSWDIR)\htmltag.obj \
|
||||
$(MSWDIR)\htmlwin.obj \
|
||||
$(MSWDIR)\htmprint.obj \
|
||||
$(MSWDIR)\m_dflist.obj \
|
||||
$(MSWDIR)\m_fonts.obj \
|
||||
$(MSWDIR)\m_hline.obj \
|
||||
$(MSWDIR)\m_image.obj \
|
||||
@ -826,6 +827,8 @@ $(MSWDIR)\htmlwin.obj: $(HTMLDIR)\htmlwin.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\htmprint.obj: $(HTMLDIR)\htmprint.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\m_dflist.obj: $(HTMLDIR)\m_dflist.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\m_fonts.obj: $(HTMLDIR)\m_fonts.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\m_hline.obj: $(HTMLDIR)\m_hline.$(SRCSUFF)
|
||||
|
@ -1,6 +1,6 @@
|
||||
|
||||
|
||||
# This file was automatically generated by tmake at 23:50, 1999/12/15
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE BCC.T!
|
||||
|
||||
#
|
||||
@ -109,7 +109,6 @@ COMMONOBJS = \
|
||||
$(MSWDIR)\ctrlcmn.obj \
|
||||
$(MSWDIR)\ctrlsub.obj \
|
||||
$(MSWDIR)\date.obj \
|
||||
$(MSWDIR)\datetime.obj \
|
||||
$(MSWDIR)\datstrm.obj \
|
||||
$(MSWDIR)\db.obj \
|
||||
$(MSWDIR)\dbtable.obj \
|
||||
@ -146,7 +145,6 @@ COMMONOBJS = \
|
||||
$(MSWDIR)\lboxcmn.obj \
|
||||
$(MSWDIR)\list.obj \
|
||||
$(MSWDIR)\log.obj \
|
||||
$(MSWDIR)\longlong.obj \
|
||||
$(MSWDIR)\memory.obj \
|
||||
$(MSWDIR)\menucmn.obj \
|
||||
$(MSWDIR)\module.obj \
|
||||
@ -476,8 +474,6 @@ $(MSWDIR)\ctrlsub.obj: $(COMMDIR)\ctrlsub.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\date.obj: $(COMMDIR)\date.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\datetime.obj: $(COMMDIR)\datetime.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\datstrm.obj: $(COMMDIR)\datstrm.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\db.obj: $(COMMDIR)\db.$(SRCSUFF)
|
||||
@ -550,8 +546,6 @@ $(MSWDIR)\list.obj: $(COMMDIR)\list.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\log.obj: $(COMMDIR)\log.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\longlong.obj: $(COMMDIR)\longlong.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\memory.obj: $(COMMDIR)\memory.$(SRCSUFF)
|
||||
|
||||
$(MSWDIR)\menucmn.obj: $(COMMDIR)\menucmn.$(SRCSUFF)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# This file was automatically generated by tmake at 23:50, 1999/12/15
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE DOS.T!
|
||||
|
||||
#
|
||||
@ -95,7 +95,6 @@ COMMONOBJS1 = \
|
||||
$(COMMDIR)\ctrlcmn.obj \
|
||||
$(COMMDIR)\ctrlsub.obj \
|
||||
$(COMMDIR)\date.obj \
|
||||
$(COMMDIR)\datetime.obj \
|
||||
$(COMMDIR)\datstrm.obj \
|
||||
$(COMMDIR)\db.obj \
|
||||
$(COMMDIR)\dbtable.obj \
|
||||
@ -132,7 +131,6 @@ COMMONOBJS1 = \
|
||||
$(COMMDIR)\lboxcmn.obj \
|
||||
$(COMMDIR)\list.obj \
|
||||
$(COMMDIR)\log.obj \
|
||||
$(COMMDIR)\longlong.obj \
|
||||
$(COMMDIR)\memory.obj \
|
||||
$(COMMDIR)\menucmn.obj \
|
||||
$(COMMDIR)\module.obj \
|
||||
@ -768,11 +766,6 @@ $(COMMDIR)/date.obj: $*.$(SRCSUFF)
|
||||
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
|
||||
<<
|
||||
|
||||
$(COMMDIR)/datetime.obj: $*.$(SRCSUFF)
|
||||
cl @<<
|
||||
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
|
||||
<<
|
||||
|
||||
$(COMMDIR)/datstrm.obj: $*.$(SRCSUFF)
|
||||
cl @<<
|
||||
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
|
||||
@ -953,11 +946,6 @@ $(COMMDIR)/log.obj: $*.$(SRCSUFF)
|
||||
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
|
||||
<<
|
||||
|
||||
$(COMMDIR)/longlong.obj: $*.$(SRCSUFF)
|
||||
cl @<<
|
||||
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
|
||||
<<
|
||||
|
||||
$(COMMDIR)/memory.obj: $*.$(SRCSUFF)
|
||||
cl @<<
|
||||
$(CPPFLAGS) /Fo$@ /c /Tp $*.$(SRCSUFF)
|
||||
|
@ -1,4 +1,4 @@
|
||||
# This file was automatically generated by tmake at 23:50, 1999/12/15
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE G95.T!
|
||||
|
||||
#
|
||||
@ -180,6 +180,7 @@ HTMLOBJS = \
|
||||
$(HTMLDIR)/htmltag.$(OBJSUFF) \
|
||||
$(HTMLDIR)/htmlwin.$(OBJSUFF) \
|
||||
$(HTMLDIR)/htmprint.$(OBJSUFF) \
|
||||
$(HTMLDIR)/m_dflist.$(OBJSUFF) \
|
||||
$(HTMLDIR)/m_fonts.$(OBJSUFF) \
|
||||
$(HTMLDIR)/m_hline.$(OBJSUFF) \
|
||||
$(HTMLDIR)/m_image.$(OBJSUFF) \
|
||||
|
@ -1,6 +1,6 @@
|
||||
|
||||
|
||||
# This file was automatically generated by tmake at 23:50, 1999/12/15
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE SC.T!
|
||||
|
||||
# Symantec C++ makefile for the msw objects
|
||||
|
@ -1,4 +1,4 @@
|
||||
# This file was automatically generated by tmake at 23:50, 1999/12/15
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE VC.T!
|
||||
|
||||
# File: makefile.vc
|
||||
@ -330,6 +330,7 @@ HTMLOBJS = ..\html\$D\helpctrl.obj \
|
||||
..\html\$D\htmltag.obj \
|
||||
..\html\$D\htmlwin.obj \
|
||||
..\html\$D\htmprint.obj \
|
||||
..\html\$D\m_dflist.obj \
|
||||
..\html\$D\m_fonts.obj \
|
||||
..\html\$D\m_hline.obj \
|
||||
..\html\$D\m_image.obj \
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/binb/wmake.exe
|
||||
|
||||
# This file was automatically generated by tmake at 23:50, 1999/12/15
|
||||
# This file was automatically generated by tmake at 17:50, 1999/12/18
|
||||
# DO NOT CHANGE THIS FILE, YOUR CHANGES WILL BE LOST! CHANGE WAT.T!
|
||||
|
||||
#
|
||||
|
@ -647,6 +647,10 @@ SOURCE=.\html\m_list.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\html\m_dflist.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\html\m_pre.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
@ -637,6 +637,10 @@ SOURCE=.\html\m_list.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\html\m_dflist.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\html\m_pre.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
Loading…
Reference in New Issue
Block a user