Skip to content

Commit

Permalink
Move to autowidth2.h all the prototypes of non-static autowidth2.c fu…
Browse files Browse the repository at this point in the history
…nctions
  • Loading branch information
gioele committed Nov 6, 2016
1 parent b9dfcd2 commit 8927974
Show file tree
Hide file tree
Showing 12 changed files with 20 additions and 19 deletions.
1 change: 1 addition & 0 deletions fontforge/Makefile.am
Expand Up @@ -38,6 +38,7 @@ noinst_HEADERS = \
autohint.h \
autosave.h \
autotrace.h \
autowidth2.h \
fontforgeui.h sftextfieldP.h configure-fontforge.h views.h \
flaglist.h strlist.h charview_private.h cvundoes.h tables.h

Expand Down
3 changes: 2 additions & 1 deletion fontforge/autowidth2.c
Expand Up @@ -24,6 +24,8 @@
* OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "autowidth2.h"

#include "fontforgevw.h"
#include "cvundoes.h"
#include <math.h>
Expand All @@ -32,7 +34,6 @@

#define DENOM_FACTOR_OF_EMSIZE 50.0

#include "autowidth2.h"
#include "edgelist2.h"

static int aw2_bbox_separation(AW_Glyph *g1, AW_Glyph *g2, AW_Data *all) {
Expand Down
10 changes: 10 additions & 0 deletions fontforge/autowidth2.h
Expand Up @@ -27,6 +27,9 @@
#ifndef _AUTOWIDTH2_H
# define _AUTOWIDTH2_H

#include "baseviews.h"
#include "splinefont.h"

typedef struct aw_glyph {
SplineChar *sc;
DBounds bb;
Expand Down Expand Up @@ -81,4 +84,11 @@ extern void FFPy_AWGlyphFree(AW_Glyph *me);
extern void FFPy_AWDataFree(AW_Data *all);
#endif /* PYTHON */

extern SplineChar ***GlyphClassesFromNames(SplineFont *sf, char **classnames, int class_cnt);

extern void AutoWidth2(FontViewBase *fv, int separation, int min_side, int max_side, int chunk_height, int loop_cnt);
extern void AutoKern2BuildClasses(SplineFont *sf, int layer, SplineChar **leftglyphs,SplineChar **rightglyphs, struct lookup_subtable *sub, int separation, int min_kern, int touching, int only_closer, int autokern, real good_enough);
extern void AutoKern2NewClass(SplineFont *sf, int layer, char **leftnames, char **rightnames, int lcnt, int rcnt, void (*kcAddOffset)(void *data,int left_index, int right_index,int offset), void *data, int separation, int min_kern, int from_closest_approach, int only_closer, int chunk_height);
extern void GuessOpticalOffset(SplineChar *sc, int layer, real *_loff, real *_roff, int chunk_height);

#endif /* _AUTOWIDTH2_H */
15 changes: 0 additions & 15 deletions fontforge/baseviews.h
Expand Up @@ -572,27 +572,12 @@ extern void FVB_MakeNamelist(FontViewBase *fv, FILE *file);
*/
extern void FVTitleUpdate(FontViewBase *fv);

extern void AutoWidth2(FontViewBase *fv,int separation,int min_side,int max_side,
int chunk_height, int loop_cnt);
extern void GuessOpticalOffset(SplineChar *sc,int layer,real *_loff, real *_roff,
int chunk_height );
extern void AutoKern2(SplineFont *sf, int layer,SplineChar **left,SplineChar **right,
struct lookup_subtable *into,
int separation, int min_kern, int from_closest_approach, int only_closer,
int chunk_height,
void (*addkp)(void *data,SplineChar *left,SplineChar *r,int off),
void *data);
extern void AutoKern2NewClass(SplineFont *sf,int layer,char **leftnames, char **rightnames,
int lcnt, int rcnt,
void (*kcAddOffset)(void *data,int left_index, int right_index,int offset), void *data,
int separation, int min_kern, int from_closest_approach, int only_closer,
int chunk_height);
extern void AutoKern2BuildClasses(SplineFont *sf,int layer,
SplineChar **leftglyphs,SplineChar **rightglyphs,
struct lookup_subtable *sub,
int separation, int min_kern, int touching, int only_closer,
int autokern,
real good_enough);

extern void MVSelectFirstKerningTable(struct metricsview *mv);

Expand Down
1 change: 1 addition & 0 deletions fontforge/python.c
Expand Up @@ -48,6 +48,7 @@ extern int old_sfnt_flags;

#include "autohint.h"
#include "autotrace.h"
#include "autowidth2.h"
#include "fontforgevw.h"
#include "cvundoes.h"
#include "ttf.h"
Expand Down
1 change: 1 addition & 0 deletions fontforge/scripting.c
Expand Up @@ -28,6 +28,7 @@

#include "autohint.h"
#include "autotrace.h"
#include "autowidth2.h"
#include "fontforge.h"
#include "cvundoes.h"
#include <gfile.h>
Expand Down
3 changes: 0 additions & 3 deletions fontforge/splinefont.h
Expand Up @@ -3359,9 +3359,6 @@ extern bigreal SFXHeight(SplineFont *sf, int layer, int return_error);
extern bigreal SFAscender(SplineFont *sf, int layer, int return_error);
extern bigreal SFDescender(SplineFont *sf, int layer, int return_error);

extern SplineChar ***GlyphClassesFromNames(SplineFont *sf,char **classnames,
int class_cnt );

extern void SCRemoveKern(SplineChar* sc);
extern void SCRemoveVKern(SplineChar* sc);

Expand Down
1 change: 1 addition & 0 deletions fontforgeexe/autowidth2dlg.c
Expand Up @@ -24,6 +24,7 @@
* OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "autowidth2.h"
#include "fontforgeui.h"
#include <math.h>
#include <ustring.h>
Expand Down
1 change: 1 addition & 0 deletions fontforgeexe/charinfo.c
Expand Up @@ -26,6 +26,7 @@
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

#include "autowidth2.h"
#include "fontforgeui.h"
#include "cvundoes.h"
#include <ustring.h>
Expand Down
1 change: 1 addition & 0 deletions fontforgeexe/fontview.c
Expand Up @@ -32,6 +32,7 @@

#include "autosave.h"
#include "autotrace.h"
#include "autowidth2.h"
#include "fontforgeui.h"
#include "cvundoes.h"
#include "groups.h"
Expand Down
1 change: 1 addition & 0 deletions fontforgeexe/kernclass.c
Expand Up @@ -24,6 +24,7 @@
* OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "autowidth2.h"
#include "fontforgeui.h"
#include <gkeysym.h>
#include <string.h>
Expand Down
1 change: 1 addition & 0 deletions fontforgeexe/lookupui.c
Expand Up @@ -25,6 +25,7 @@
* OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "autowidth2.h"
#include "fontforgeui.h"
#include <chardata.h>
#include <utype.h>
Expand Down

0 comments on commit 8927974

Please sign in to comment.