Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Motif: scale widget Problem

Reply
Thread Tools

Motif: scale widget Problem

 
 
Daniel Tscharnuter
Guest
Posts: n/a
 
      01-24-2004
Hello!

First of all, I am new to C++.

The problem with the scale widget is that I get a segmentation fault when I
want to create it with more than zero decimal numbers.

beta_scale_ = XtVaCreateManagedWidget("betascale",
xmScaleWidgetClass, form_left,
XmNtitleString, title,
XmNorientation, XmHORIZONTAL,
XmNminimum, 1,
XmNmaximum, 10000,
XmNdecimalPoints, 2,
XmNshowValue, True,
XmNvalue, 100,
XmNwidth, SCALE_WIDTH,
XmNheight, SCALE_HEIGHT,
NULL);

It worked that way in C, but in C++ it only works with XmNdecimalPoints set
to 0.

Thanks,
Daniel

--
Port State Service
666/tcp open doom
 
Reply With Quote
 
 
 
 
Victor Bazarov
Guest
Posts: n/a
 
      01-24-2004
"Daniel Tscharnuter" <(E-Mail Removed)> wrote...
> First of all, I am new to C++.


Your problem while shows up in C++ really has nothing to do with C++
but rather with Motif and its widgets.

>
> The problem with the scale widget is that I get a segmentation fault when

I
> want to create it with more than zero decimal numbers.
>
> beta_scale_ = XtVaCreateManagedWidget("betascale",
> xmScaleWidgetClass, form_left,
> XmNtitleString, title,
> XmNorientation, XmHORIZONTAL,
> XmNminimum, 1,
> XmNmaximum, 10000,
> XmNdecimalPoints, 2,
> XmNshowValue, True,
> XmNvalue, 100,
> XmNwidth, SCALE_WIDTH,
> XmNheight, SCALE_HEIGHT,
> NULL);
>
> It worked that way in C, but in C++ it only works with XmNdecimalPoints

set
> to 0.


You need to ask about it in a newsgroup dedicated to Motif. This NG only
deals with C++ _language_ issues, and yours isn't one of them.

Victor


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
The Definitive Chord & Scale Bible - Literally EVERY chord and scale! Kind of Blue2 Digital Photography 1 02-08-2005 10:14 PM
Re: [Tkinter-discuss] Please help -- Tkinter Scale widget withDoubleVar is acting weird Jeff Epler Python 0 08-23-2004 02:31 PM
Re: [Tkinter-discuss] Please help -- Tkinter Scale widget withDoubleVar is acting weird Jeff Epler Python 0 08-20-2004 12:07 PM
Re: Please help -- Tkinter Scale widget with DoubleVar is actingweird Fredrik Lundh Python 0 08-19-2004 05:01 PM
Tkinter, scale widget, and mouse clicks John Fouhy Python 2 06-25-2004 12:49 AM



Advertisments