mirror of
git://projects.qi-hardware.com/eda-tools.git
synced 2024-11-05 03:38:05 +02:00
eeshow/: fix some whitespace issues
- trailing space - space before semicolon - indentation with spaces instead of tabs (copy & paste)
This commit is contained in:
parent
e18c146323
commit
1c6116a8d6
@ -8,6 +8,8 @@ Parsing and input processing:
|
|||||||
Data model:
|
Data model:
|
||||||
- implement destructors
|
- implement destructors
|
||||||
- check for memory leaks
|
- check for memory leaks
|
||||||
|
- sheets appearing multiple times are parsed anew each time. Should we try
|
||||||
|
to combine them ?
|
||||||
|
|
||||||
Visualization (dwg.c and such):
|
Visualization (dwg.c and such):
|
||||||
- glabel: build for "right" style, then rotate poly (like hlabel)
|
- glabel: build for "right" style, then rotate poly (like hlabel)
|
||||||
@ -21,6 +23,8 @@ Visualization (dwg.c and such):
|
|||||||
|
|
||||||
Rendering:
|
Rendering:
|
||||||
- better text size guessing also for FIG
|
- better text size guessing also for FIG
|
||||||
|
- consider switching to Hershey fonts (that's what eeschema uses, right ?)
|
||||||
|
(goal: prevent font geometry from changing when scaling)
|
||||||
- support fonts attributes ?
|
- support fonts attributes ?
|
||||||
- support line thickness ?
|
- support line thickness ?
|
||||||
- ~ as overline (grep for ~ in out.fig)
|
- ~ as overline (grep for ~ in out.fig)
|
||||||
@ -34,3 +38,7 @@ GUI:
|
|||||||
- fonts grow beyond their bounding boxes when zooming in
|
- fonts grow beyond their bounding boxes when zooming in
|
||||||
- dragging can be slow. maybe reusing old content and only redrawing new
|
- dragging can be slow. maybe reusing old content and only redrawing new
|
||||||
will help ?
|
will help ?
|
||||||
|
|
||||||
|
On-going:
|
||||||
|
- use Pango to support markup in overlay boxes:
|
||||||
|
https://developer.gnome.org/pango/unstable/PangoMarkupFormat.html
|
||||||
|
@ -110,7 +110,7 @@ static void fig_circ(void *ctx, int x, int y, int r,
|
|||||||
{
|
{
|
||||||
// Type Thick Depth StyleV Cx Rx Sx Ex
|
// Type Thick Depth StyleV Cx Rx Sx Ex
|
||||||
// SubTy Color Pen Dir Cy Ry Sy Ey
|
// SubTy Color Pen Dir Cy Ry Sy Ey
|
||||||
// Style FillCol AreaFil Angle
|
// Style FillCol AreaFil Angle
|
||||||
printf("1 3 0 %d %d %d %d -1 %d 0.0 1 0.0 %d %d %d %d %d %d %d %d\n",
|
printf("1 3 0 %d %d %d %d -1 %d 0.0 1 0.0 %d %d %d %d %d %d %d %d\n",
|
||||||
color == -1 ? 0 : WIDTH_COMP_DWG, color, fill_color, layer,
|
color == -1 ? 0 : WIDTH_COMP_DWG, color, fill_color, layer,
|
||||||
fill_color == -1 ? -1 : 20,
|
fill_color == -1 ? -1 : 20,
|
||||||
|
@ -58,7 +58,7 @@ void gfx_arc(int x, int y, int r, int sa, int ea,
|
|||||||
int color, int fill_color, unsigned layer);
|
int color, int fill_color, unsigned layer);
|
||||||
void gfx_text(int x, int y, const char *s, unsigned size,
|
void gfx_text(int x, int y, const char *s, unsigned size,
|
||||||
enum text_align align, int rot, unsigned color, unsigned layer);
|
enum text_align align, int rot, unsigned color, unsigned layer);
|
||||||
void gfx_tag(const char *s,
|
void gfx_tag(const char *s,
|
||||||
unsigned points, const int x[points], int const y[points]);
|
unsigned points, const int x[points], int const y[points]);
|
||||||
unsigned gfx_text_width(const char *s, unsigned size);
|
unsigned gfx_text_width(const char *s, unsigned size);
|
||||||
|
|
||||||
|
@ -312,7 +312,7 @@ static const void *get_data(git_repository *repo, git_tree_entry *entry,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (verbose > 2) {
|
if (verbose > 2) {
|
||||||
git_buf buf = { 0 } ;
|
git_buf buf = { 0 };
|
||||||
|
|
||||||
if (git_object_short_id(&buf, obj)) {
|
if (git_object_short_id(&buf, obj)) {
|
||||||
const git_error *e = giterr_last();
|
const git_error *e = giterr_last();
|
||||||
@ -459,7 +459,7 @@ struct vcs_git *vcs_git_open(const char *revision, const char *name,
|
|||||||
|
|
||||||
|
|
||||||
void vcs_git_read(void *ctx, struct file *file,
|
void vcs_git_read(void *ctx, struct file *file,
|
||||||
bool (*parse)(const struct file *file, void *user, const char *line),
|
bool (*parse)(const struct file *file, void *user, const char *line),
|
||||||
void *user)
|
void *user)
|
||||||
{
|
{
|
||||||
const struct vcs_git *vcs_git = ctx;
|
const struct vcs_git *vcs_git = ctx;
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
|
|
||||||
struct aoi {
|
struct aoi {
|
||||||
int x, y, w, h; /* activation box, eeschema coordinates */
|
int x, y, w, h; /* activation box, eeschema coordinates */
|
||||||
/* points to hovered aoi, or NULL */
|
/* points to hovered aoi, or NULL */
|
||||||
|
|
||||||
bool (*hover)(void *user, bool on);
|
bool (*hover)(void *user, bool on);
|
||||||
|
@ -124,7 +124,7 @@ struct overlay *overlay_add(struct overlay **overlays, const char *s,
|
|||||||
{
|
{
|
||||||
struct overlay *over;
|
struct overlay *over;
|
||||||
struct overlay **anchor;
|
struct overlay **anchor;
|
||||||
|
|
||||||
over = alloc_type(struct overlay);
|
over = alloc_type(struct overlay);
|
||||||
over->s = stralloc(s);
|
over->s = stralloc(s);
|
||||||
|
|
||||||
|
@ -153,7 +153,7 @@ static void pan_update(struct gui_ctx *ctx, int x, int y)
|
|||||||
{
|
{
|
||||||
if (!ctx->panning)
|
if (!ctx->panning)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
ctx->x -= (x - ctx->pan_x) << ctx->zoom;
|
ctx->x -= (x - ctx->pan_x) << ctx->zoom;
|
||||||
ctx->y -= (y - ctx->pan_y) << ctx->zoom;
|
ctx->y -= (y - ctx->pan_y) << ctx->zoom;
|
||||||
ctx->pan_x = x;
|
ctx->pan_x = x;
|
||||||
@ -433,7 +433,7 @@ static void select_subsheet(void *user)
|
|||||||
const struct sheet_aoi_ctx *aoi_ctx = user;
|
const struct sheet_aoi_ctx *aoi_ctx = user;
|
||||||
struct gui_ctx *ctx = aoi_ctx->gui_ctx;
|
struct gui_ctx *ctx = aoi_ctx->gui_ctx;
|
||||||
const struct sch_obj *obj = aoi_ctx->obj;
|
const struct sch_obj *obj = aoi_ctx->obj;
|
||||||
struct gui_sheet *sheet;
|
struct gui_sheet *sheet;
|
||||||
|
|
||||||
for (sheet = ctx->sheets; sheet; sheet = sheet->next)
|
for (sheet = ctx->sheets; sheet; sheet = sheet->next)
|
||||||
if (sheet->sch == obj->u.sheet.sheet) {
|
if (sheet->sch == obj->u.sheet.sheet) {
|
||||||
|
@ -235,7 +235,7 @@ static bool lib_parse_line(const struct file *file,
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
if (sscanf(line, "X %ms %ms %d %d %d %c %d %d %u %u %c",
|
if (sscanf(line, "X %ms %ms %d %d %d %c %d %d %u %u %c",
|
||||||
&obj->u.pin.name, &obj->u.pin.number,
|
&obj->u.pin.name, &obj->u.pin.number,
|
||||||
&obj->u.pin.x, &obj->u.pin.y, &obj->u.pin.length,
|
&obj->u.pin.x, &obj->u.pin.y, &obj->u.pin.length,
|
||||||
&obj->u.pin.orient,
|
&obj->u.pin.orient,
|
||||||
&obj->u.pin.number_size, &obj->u.pin.name_size,
|
&obj->u.pin.number_size, &obj->u.pin.name_size,
|
||||||
|
@ -91,7 +91,7 @@ struct comp {
|
|||||||
const char *name;
|
const char *name;
|
||||||
unsigned units;
|
unsigned units;
|
||||||
|
|
||||||
unsigned visible; /* visible fields, bit mask */
|
unsigned visible; /* visible fields, bit mask */
|
||||||
bool show_pin_name;
|
bool show_pin_name;
|
||||||
bool show_pin_num;
|
bool show_pin_num;
|
||||||
unsigned name_offset;
|
unsigned name_offset;
|
||||||
|
@ -84,7 +84,7 @@ while read line; do
|
|||||||
|
|
||||||
$quiet || echo "$file" 1>&2
|
$quiet || echo "$file" 1>&2
|
||||||
./eeshow $libs `dirname "$1"`/$file \
|
./eeshow $libs `dirname "$1"`/$file \
|
||||||
-- fig $template "TITLE=$name" NUMBER=$num |
|
-- fig $template "TITLE=$name" NUMBER=$num |
|
||||||
fig2dev -L pdf >_tmp.pdf
|
fig2dev -L pdf >_tmp.pdf
|
||||||
pdfunite "$out" _tmp.pdf _tmp2.pdf
|
pdfunite "$out" _tmp.pdf _tmp2.pdf
|
||||||
mv _tmp2.pdf "$out"
|
mv _tmp2.pdf "$out"
|
||||||
|
@ -28,11 +28,11 @@ enum text_style {
|
|||||||
};
|
};
|
||||||
|
|
||||||
struct text {
|
struct text {
|
||||||
const char *s;
|
const char *s;
|
||||||
int size;
|
int size;
|
||||||
int x, y;
|
int x, y;
|
||||||
int rot;
|
int rot;
|
||||||
enum text_align hor;
|
enum text_align hor;
|
||||||
enum text_align vert;
|
enum text_align vert;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user