Quelltext /~heha/ewa/Reluktanzmotor/cdesk-201007.zip/cdesk.h

#pragma once
/* Globale Projektdefinitionen, die auch für plotxy und editx gelten
 */
#include "compat.h"
#include <windowsx.h>

extern HINSTANCE ghInstance;	// Wo die Ressourcen herkommen
extern HWND ghMainWnd,ghDlgWnd;	// Hauptfenster; nichtmodaler Dialog (zz. unbenutzt)
extern TCHAR sDecimal[2];	// Dezimaltrennzeichen (Punkt oder Komma)
extern TCHAR sTime[2];		// Uhrzeit-Trennzeichen (typ. Doppelpunkt)
extern bool iMeasure;		// 0 = metrisch, 1 = zöllig

struct RECTS{
 short left,top,right,bottom;
 short width() const {return right-left;}
 short height() const {return bottom-top;}
 RECTS() {}
 RECTS(const RECT&r):left(short(r.left)), top(short(r.top)), right(short(r.right)), bottom(short(r.bottom)) {}
 RECTS&operator=(const RECT&r) {left=short(r.left); top=short(r.top); right=short(r.right); bottom=short(r.bottom);return*this;}
 void setrect(RECT&r) const {r.left=left; r.top=top; r.right=right; r.bottom=bottom;}
};


//#define T(x) TEXT(x)
int FillCombo(HWND,UINT,UINT,int=-1);
INT_PTR CALLBACK SettingsDlgProc(HWND Wnd, UINT Msg, WPARAM wParam, LPARAM lParam);

extern struct CONFIG{
 RECTS rcMain;
 POINTS simupos;
 BYTE swShow;
 BYTE ComNr;
 static bool load();
 static void save();
}config;

void EnableDlgItem(HWND,UINT,bool);
Vorgefundene Kodierung: UTF-80