git.asbjorn.biz
/
swftools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f2edb50
)
Implement -t (--stop) option.
author
kramm
<kramm>
Mon, 17 Jun 2002 11:31:20 +0000
(11:31 +0000)
committer
kramm
<kramm>
Mon, 17 Jun 2002 11:31:20 +0000
(11:31 +0000)
pdf2swf/SWFOutputDev.cc
patch
|
blob
|
history
pdf2swf/SWFOutputDev.h
patch
|
blob
|
history
pdf2swf/pdf2swf.cc
patch
|
blob
|
history
pdf2swf/swfoutput.cc
patch
|
blob
|
history
pdf2swf/swfoutput.h
patch
|
blob
|
history
diff --git
a/pdf2swf/SWFOutputDev.cc
b/pdf2swf/SWFOutputDev.cc
index
17e3788
..
46bfb06
100644
(file)
--- a/
pdf2swf/SWFOutputDev.cc
+++ b/
pdf2swf/SWFOutputDev.cc
@@
-1729,6
+1729,11
@@
int pdfswf_numpages()
return doc->getNumPages();
}
return doc->getNumPages();
}
+void pdfswf_insertstop()
+{
+ insertstoptag = 1;
+}
+
int closed=0;
void pdfswf_close()
{
int closed=0;
void pdfswf_close()
{
diff --git
a/pdf2swf/SWFOutputDev.h
b/pdf2swf/SWFOutputDev.h
index
e1fa38d
..
6db523f
100644
(file)
--- a/
pdf2swf/SWFOutputDev.h
+++ b/
pdf2swf/SWFOutputDev.h
@@
-18,6
+18,7
@@
void pdfswf_linksopennewwindow();
void pdfswf_jpegquality(int);
void pdfswf_performconversion();
void pdfswf_storeallcharacters();
void pdfswf_jpegquality(int);
void pdfswf_performconversion();
void pdfswf_storeallcharacters();
+void pdfswf_insertstop();
int pdfswf_numpages();
void pdfswf_convertpage(int page) ;
int pdfswf_numpages();
void pdfswf_convertpage(int page) ;
diff --git
a/pdf2swf/pdf2swf.cc
b/pdf2swf/pdf2swf.cc
index
1122126
..
782e138
100644
(file)
--- a/
pdf2swf/pdf2swf.cc
+++ b/
pdf2swf/pdf2swf.cc
@@
-115,6
+115,11
@@
int args_callback_option(char*name,char*val) {
pdfswf_linksopennewwindow();
return 0;
}
pdfswf_linksopennewwindow();
return 0;
}
+ else if (!strcmp(name, "t"))
+ {
+ pdfswf_insertstop();
+ return 0;
+ }
else if (!strcmp(name, "f"))
{
pdfswf_storeallcharacters();
else if (!strcmp(name, "f"))
{
pdfswf_storeallcharacters();
@@
-231,6
+236,7
@@
struct options_t options[] =
{"L","preloader"},
{"b","defaultviewer"},
{"l","defaultpreloader"},
{"L","preloader"},
{"b","defaultviewer"},
{"l","defaultpreloader"},
+ {"t","stop"},
{0,0}
};
{0,0}
};
@@
-272,6
+278,7
@@
void args_callback_usage(char*name)
#endif
printf("-f --fonts Store full fonts in SWF. (Don't reduce to used characters)\n");
printf("-V --version Print program version\n");
#endif
printf("-f --fonts Store full fonts in SWF. (Don't reduce to used characters)\n");
printf("-V --version Print program version\n");
+ printf("-t --stop Insert a \"Stop\" Tag in every frame (don't turn pages automatically)\n");
#ifndef SYSTEM_BACKTICKS
printf("The following might not work because your system call doesn't support command substitution:\n");
#endif
#ifndef SYSTEM_BACKTICKS
printf("The following might not work because your system call doesn't support command substitution:\n");
#endif
diff --git
a/pdf2swf/swfoutput.cc
b/pdf2swf/swfoutput.cc
index
2161d9e
..
330c890
100644
(file)
--- a/
pdf2swf/swfoutput.cc
+++ b/
pdf2swf/swfoutput.cc
@@
-36,6
+36,7
@@
int drawonlyshapes=0;
int jpegquality=85;
int storeallcharacters=0;
int enablezlib=0;
int jpegquality=85;
int storeallcharacters=0;
int enablezlib=0;
+int insertstoptag=0;
static int flag_protected = 0;
typedef unsigned char u8;
static int flag_protected = 0;
typedef unsigned char u8;
@@
-969,6
+970,14
@@
static void endpage(struct swfoutput*obj)
endtext();
while(clippos)
swfoutput_endclip(obj);
endtext();
while(clippos)
swfoutput_endclip(obj);
+
+ if(insertstoptag) {
+ ActionTAG*atag=0;
+ atag = action_Stop(atag);
+ atag = action_End(atag);
+ tag = swf_InsertTag(tag,ST_DOACTION);
+ swf_ActionSet(tag,atag);
+ }
tag = swf_InsertTag(tag,ST_SHOWFRAME);
}
tag = swf_InsertTag(tag,ST_SHOWFRAME);
}
diff --git
a/pdf2swf/swfoutput.h
b/pdf2swf/swfoutput.h
index
1c66788
..
896de37
100644
(file)
--- a/
pdf2swf/swfoutput.h
+++ b/
pdf2swf/swfoutput.h
@@
-21,6
+21,7
@@
extern int ignoredraworder; //default:0
extern int drawonlyshapes; //default:0
extern int jpegquality; //default:100;
extern int storeallcharacters; // default:0
extern int drawonlyshapes; //default:0
extern int jpegquality; //default:100;
extern int storeallcharacters; // default:0
+extern int insertstoptag; //default:0
typedef long int twip;
typedef long int twip;