25 Description = QObject::tr(
"MOS field-effect transistor");
36 p->
Props.first()->Value =
Props.first()->Value;
45 Name = QObject::tr(
"n-MOSFET");
46 BitmapFile = (
char *)
"nmosfet";
48 if(getNewOne)
return new MOSFET();
55 Name = QObject::tr(
"p-MOSFET");
56 BitmapFile = (
char *)
"pmosfet";
60 p->
Props.first()->Value =
"pfet";
61 p->
Props.next()->Value =
"-1.0 V";
71 Name = QObject::tr(
"depletion MOSFET");
72 BitmapFile = (
char *)
"dmosfet";
77 p->
Props.next()->Value =
"-1.0 V";
87 Lines.append(
new Line(-14,-13,-14, 13,QPen(QPen::darkBlue,3)));
88 Lines.append(
new Line(-30, 0,-14, 0,QPen(QPen::darkBlue,2)));
90 Lines.append(
new Line(-10,-11, 0,-11,QPen(QPen::darkBlue,2)));
91 Lines.append(
new Line( 0,-11, 0,-30,QPen(QPen::darkBlue,2)));
92 Lines.append(
new Line(-10, 11, 0, 11,QPen(QPen::darkBlue,2)));
93 Lines.append(
new Line( 0, 0, 0, 30,QPen(QPen::darkBlue,2)));
94 Lines.append(
new Line(-10, 0, 0, 0,QPen(QPen::darkBlue,2)));
96 Lines.append(
new Line(-10,-16,-10, -7,QPen(QPen::darkBlue,3)));
97 Lines.append(
new Line(-10, 7,-10, 16,QPen(QPen::darkBlue,3)));
99 if(
Props.first()->Value ==
"nfet") {
100 Lines.append(
new Line( -9, 0, -4, -5,QPen(QPen::darkBlue,2)));
101 Lines.append(
new Line( -9, 0, -4, 5,QPen(QPen::darkBlue,2)));
104 Lines.append(
new Line( -1, 0, -6, -5,QPen(QPen::darkBlue,2)));
105 Lines.append(
new Line( -1, 0, -6, 5,QPen(QPen::darkBlue,2)));
108 if((
Props.next()->Value.stripWhiteSpace().at(0) ==
'-') ==
109 (
Props.first()->Value ==
"nfet"))
110 Lines.append(
new Line(-10, -8,-10, 8,QPen(QPen::darkBlue,3)));
112 Lines.append(
new Line(-10, -4,-10, 4,QPen(QPen::darkBlue,3)));
125 QString
s =
"MOSFET:"+
Name;
129 s +=
" "+p1->Connection->Name;
130 s +=
" "+
Ports.at(2)->Connection->Name;
134 s +=
" "+p2->Name+
"=\""+p2->Value+
"\"";