Druck Position eines Textes ?

  • Follow


Hallo Leute,

ich habe hier ein kleines Problem beim ausrichten meines Textes beim
Drucken.
ich benutze die Funktion:

pDC->TextOut(310,690,"Hier soll der text hin ");

das Problem ist das wenn ich einen Anderen Drucker habe der Tex auch an
einer anderen Stelle ist. So ich kann mir ja mit:

    int a = rcClient.Height();
    int b = rcClient.Width();

    int c = pDC->GetDeviceCaps(PHYSICALWIDTH);
    int d = pDC->GetDeviceCaps(PHYSICALHEIGHT);

disen beiden Methoden den Druckbereich holen auf dem ich drucken kann.
Nur wie teile ich diesen Druck bereich nun ein damit bei jedem Drucker
die Position des Textes gleich ist ? 


Danke Jens

0
Reply coolsero 3/15/2006 12:19:25 PM

<coolsero@gmx.de> schrieb im Newsbeitrag 
news:1142425164.975402.83740@p10g2000cwp.googlegroups.com...
> Hallo Leute,
>
> ich habe hier ein kleines Problem beim ausrichten meines Textes beim
> Drucken.
> ich benutze die Funktion:
>
> pDC->TextOut(310,690,"Hier soll der text hin ");
>
> das Problem ist das wenn ich einen Anderen Drucker habe der Tex auch 
> an
> einer anderen Stelle ist. So ich kann mir ja mit:
>
>    int a = rcClient.Height();
>    int b = rcClient.Width();
>
>    int c = pDC->GetDeviceCaps(PHYSICALWIDTH);
>    int d = pDC->GetDeviceCaps(PHYSICALHEIGHT);
>
> disen beiden Methoden den Druckbereich holen auf dem ich drucken 
> kann.
> Nur wie teile ich diesen Druck bereich nun ein damit bei jedem 
> Drucker
> die Position des Textes gleich ist ?

Doh! 


0
Reply me4 (18697) 3/15/2006 1:27:28 PM


coolsero@gmx.de wrote:
> Hallo Leute,
> 
> ich habe hier ein kleines Problem [...]

Wrong newsgroup.  Try something with 'windows' in its name.  And
follow the rules of the newsgroup you post to, especially regarding
the [human] language it's in.

V
-- 
Please remove capital As from my address when replying by mail
0
Reply v.Abazarov (13255) 3/15/2006 2:23:13 PM

Victor Bazarov wrote:

> coolsero@gmx.de wrote:
>> Hallo Leute,
>> 
>> ich habe hier ein kleines Problem [...]
> 
> Wrong newsgroup.  Try something with 'windows' in its name.  And
> follow the rules of the newsgroup you post to, especially regarding
> the [human] language it's in.

Hmm, just out of curiosity: Where is the rule that says you may only post in
english here?

0
Reply ramagnus (3485) 3/15/2006 4:28:03 PM

Rolf Magnus wrote:
> Victor Bazarov wrote:
> 
> 
>>coolsero@gmx.de wrote:
>>
>>>Hallo Leute,
>>>
>>>ich habe hier ein kleines Problem [...]
>>
>>Wrong newsgroup.  Try something with 'windows' in its name.  And
>>follow the rules of the newsgroup you post to, especially regarding
>>the [human] language it's in.
> 
> 
> Hmm, just out of curiosity: Where is the rule that says you may only post in
> english here?

Read my post.  And others' posts that say the same thing.  That's the
rule I am referring to.  If you need an international law that says what
I said, there isn't any.

Curiosity kill[fil]ed the cat, Rolf.
0
Reply v.Abazarov (13255) 3/15/2006 4:36:05 PM

Rolf Magnus wrote:

> Hmm, just out of curiosity: Where is the rule that says you may only post
> in english here?

It's called "common sense".

-- 
Salu2
0
Reply JULIANALBO (791) 3/15/2006 4:39:55 PM

On Wed, 15 Mar 2006 17:28:03 +0100 Rolf Magnus <ramagnus@t-online.de>
waved a wand and this message magically appeared:

> Hmm, just out of curiosity: Where is the rule that says you may only post in
> english here?

I would have thought that seeing all these English posts would have
given you a free clue.

-- 
http://www.munted.org.uk

"Honestly, what can I possibly say to get you into my bed?" - Anon.
0
Reply alex.buell470 (478) 3/15/2006 5:17:20 PM

In article <4418435b_1@x-privat.org>, Juli�n Albo <JULIANALBO@terra.es>
writes
>Rolf Magnus wrote:
>
>> Hmm, just out of curiosity: Where is the rule that says you may only post
>> in english here?
>
>It's called "common sense".

People can post in any language the like.  The Internet is universal.
What is common sense is to use a language that the majority might
understand. 

I have noticed that very few Americans post in English :-) 

-- 
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills  Staffs  England     /\/\/\/\/
/\/\/ chris@phaedsys.org      www.phaedsys.org \/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/



0
Reply chris32 (3350) 3/15/2006 5:44:05 PM

In article <dv9f9d$uq5$03$2@news.t-online.com>, Rolf Magnus <ramagnus@t-
online.de> writes
>Victor Bazarov wrote:
>
>> coolsero@gmx.de wrote:
>>> Hallo Leute,
>>> 
>>> ich habe hier ein kleines Problem [...]
>> 
>> Wrong newsgroup.  Try something with 'windows' in its name.  And
>> follow the rules of the newsgroup you post to, especially regarding
>> the [human] language it's in.
>
>Hmm, just out of curiosity: Where is the rule that says you may only post in
>english here?

Probably written in American in the original charter when the Internet
was only on the continental US.  Perhaps it is worth re-visiting? 

I would not start a war on  languages... there are a LOT more Chinese
speakers/writers out there :-)


-- 
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\ Chris Hills  Staffs  England     /\/\/\/\/
/\/\/ chris@phaedsys.org      www.phaedsys.org \/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/



0
Reply chris32 (3350) 3/15/2006 6:02:09 PM

Victor Bazarov wrote:

> Rolf Magnus wrote:
>> Victor Bazarov wrote:
>> 
>> 
>>>coolsero@gmx.de wrote:
>>>
>>>>Hallo Leute,
>>>>
>>>>ich habe hier ein kleines Problem [...]
>>>
>>>Wrong newsgroup.  Try something with 'windows' in its name.  And
>>>follow the rules of the newsgroup you post to, especially regarding
>>>the [human] language it's in.
>> 
>> 
>> Hmm, just out of curiosity: Where is the rule that says you may only post
>> in english here?
> 
> Read my post.  And others' posts that say the same thing.  That's the
> rule I am referring to.

Well, how could someone new to the group know that? If he sees only english
postings, that doesn't automatically mean that english is the only accepted
language. And in clc++, we usually agree that such assumptions are bad
(hmm, x=5; x = x++ * x++; results in x being 42, so that must be how it is
in C++).

> If you need an international law that says what I said, there isn't any.

No, but maybe a hint in the FAQ or somesuch would be useful.

0
Reply ramagnus (3485) 3/15/2006 6:25:39 PM

Chris Hills wrote:

> People can post in any language the like.  The Internet is universal.
> What is common sense is to use a language that the majority might
> understand.

Right. And that language in this and many other groups is... ?

-- 
Salu2
0
Reply JULIANALBO (791) 3/15/2006 8:20:36 PM

Rolf Magnus wrote:
> Victor Bazarov wrote:
> 
> 
>>Rolf Magnus wrote:
>>
>>>Victor Bazarov wrote:
>>>
>>>
>>>
>>>>coolsero@gmx.de wrote:
>>>>
>>>>
>>>>>Hallo Leute,
>>>>>
>>>>>ich habe hier ein kleines Problem [...]
>>>>
>>>>Wrong newsgroup.  Try something with 'windows' in its name.  And
>>>>follow the rules of the newsgroup you post to, especially regarding
>>>>the [human] language it's in.
>>>
>>>
>>>Hmm, just out of curiosity: Where is the rule that says you may only post
>>>in english here?
>>
>>Read my post.  And others' posts that say the same thing.  That's the
>>rule I am referring to.
> 
> 
> Well, how could someone new to the group know that? If he sees only english
> postings, that doesn't automatically mean that english is the only accepted
> language. [...]

Yes, but it's a safe[r] start [than x = x++ * x++].

>>If you need an international law that says what I said, there isn't any.
> 
> 
> No, but maybe a hint in the FAQ or somesuch would be useful.

Then contact the maintainer of the FAQ.  I hope you don't need help
with that.

V
-- 
Please remove capital As from my address when replying by mail
0
Reply v.Abazarov (13255) 3/15/2006 8:59:16 PM

#include <stdio.h>

#define void nix
#define inache default
#define esli    if
#define nikogo rand(2)
#define otdixai
#define brich_ab break
#define EARTH   0
#define TO

enum swetofor{rot, gelb, green};

int main(nix)
{
         enum swetofor ampel;
         while(1.1)
         {
                 switch(ampel)
                 {
                         case rot:
                                 esli(nikogo){
                                         ampel = green;
                                         brich_ab;
                                 }
                                 sleep(8);
                                 ampel = gelb;
                                 brich_ab;
                         case gelb:
                                 ampel = green;
                                 sleep(1);
                                 brich_ab;
                         case green:
                                 sleep(10);
                                 ampel = rot;
                                 brich_ab;
                         inache:
                                 otdixai;
                 }
         }
         return TO EARTH;
}


0
Reply uval (235) 3/15/2006 9:48:04 PM

#include <stdio.h>

#define void nix
#define inache default
#define esli    if
#define nikogo rand(2)
#define otdixai
#define brich_ab break
#define HELL
#define TO      0
#define TRAFFIC HELL
#define LIGHT HELL

enum swetofor{rot, gelb, green};

int main(nix)
{
         enum swetofor ampel;
         while(1.1)
         {
                 switch(ampel)
                 {
                         case rot:
                                 esli(nikogo){
                                         ampel = green;
                                         brich_ab;
                                 }
                                 sleep(8);
                                 ampel = gelb;
                                 brich_ab;
                         case gelb:
                                 ampel = green;
                                 sleep(1);
                                 brich_ab;
                         case green:
                                 sleep(10);
                                 ampel = rot;
                                 brich_ab;
                         inache:
                                 otdixai;
                 }
         }
         return TO TRAFFIC LIGHT HELL;
}

0
Reply uval (235) 3/15/2006 9:53:27 PM

Sch=FCle Daniel wrote:
> #include <stdio.h>
>
> #define void nix
> #define inache default
> #define esli    if
> #define nikogo rand(2)
> #define otdixai
> #define brich_ab break
> #define EARTH   0
> #define TO
>
> enum swetofor{rot, gelb, green};
>
> int main(nix)
> {
>          enum swetofor ampel;
>          while(1.1)
>          {
>                  switch(ampel)
>                  {
>                          case rot:
>                                  esli(nikogo){
>                                          ampel =3D green;
>                                          brich_ab;
>                                  }
>                                  sleep(8);
>                                  ampel =3D gelb;
>                                  brich_ab;
>                          case gelb:
>                                  ampel =3D green;
>                                  sleep(1);
>                                  brich_ab;
>                          case green:
>                                  sleep(10);
>                                  ampel =3D rot;
>                                  brich_ab;
>                          inache:
>                                  otdixai;
>                  }
>          }
>          return TO EARTH;
> }

rand does not take any arguments.
there is no prototype for sleep.

REH

0
Reply spamjunk (312) 3/15/2006 9:56:06 PM

Victor Bazarov wrote:

>> No, but maybe a hint in the FAQ or somesuch would be useful.
> Then contact the maintainer of the FAQ.  I hope you don't need help
> with that.

An tell him to put it in almost 5.000 languages, many people than can't read
english may need help.

-- 
Salu2
0
Reply JULIANALBO (791) 3/15/2006 10:30:16 PM

REH <spamjunk@stny.rr.com>:
>
> Sch�le Daniel wrote:
>> #include <stdio.h>
>>
>> #define void nix

#define nix void

>> #define inache default
>> #define esli    if
>> #define nikogo rand(2)
>> #define otdixai
>> #define brich_ab break
>> #define EARTH   0
>> #define TO
>>
>> enum swetofor{rot, gelb, green};
>>
>> int main(nix)
>> {
>>          enum swetofor ampel;
>>          while(1.1)
>>          {
>>                  switch(ampel)
>>                  {
>>                          case rot:
>>                                  esli(nikogo){
>>                                          ampel = green;
>>                                          brich_ab;
>>                                  }
>>                                  sleep(8);
>>                                  ampel = gelb;
>>                                  brich_ab;
>>                          case gelb:
>>                                  ampel = green;
>>                                  sleep(1);
>>                                  brich_ab;
>>                          case green:
>>                                  sleep(10);
>>                                  ampel = rot;
>>                                  brich_ab;
>>                          inache:
>>                                  otdixai;
>>                  }
>>          }
>>          return TO EARTH;
>> }
>
> rand does not take any arguments.
> there is no prototype for sleep.
>
> REH
>
>

Maett
0
Reply no1043 (237) 3/16/2006 6:48:32 PM

why are you trolling about this? :(

0
Reply jose.diego (240) 3/17/2006 5:22:03 PM

Sch=FCle Daniel wrote:
> #include <stdio.h>
>
> #define void nix

This defines void as nix. But nix is never defined.

> #define inache default
> #define esli    if
> #define nikogo rand(2)

No prototype for rand is given. If you want stlib then you need to
include it. The rand in there does not take an argument.

> #define otdixai
> #define brich_ab break
> #define HELL
> #define TO      0
> #define TRAFFIC HELL
> #define LIGHT HELL
>
> enum swetofor{rot, gelb, green};
>
> int main(nix)
> {
>          enum swetofor ampel;
>          while(1.1)
>          {
>                  switch(ampel)

You are using ampel without ever having given it a value.

>                  {
>                          case rot:
>                                  esli(nikogo){
>                                          ampel =3D green;
>                                          brich_ab;
>                                  }
>                                  sleep(8);

No prototype for sleep.

>                                  ampel =3D gelb;
>                                  brich_ab;
>                          case gelb:
>                                  ampel =3D green;
>                                  sleep(1);
>                                  brich_ab;
>                          case green:
>                                  sleep(10);
>                                  ampel =3D rot;
>                                  brich_ab;
>                          inache:
>                                  otdixai;
>                  }
>          }
>          return TO TRAFFIC LIGHT HELL;
> }

0
Reply puppet_sock (479) 3/17/2006 6:44:10 PM

18 Replies
23 Views

(page loaded in 0.186 seconds)


Reply: