Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » Menus&Toolbars » CtrlImg::new_doc()
CtrlImg::new_doc() [message #10785] Sat, 28 July 2007 23:42 Go to next message
Mark999 is currently offline  Mark999
Messages: 6
Registered: July 2007
Promising Member
I was looking at the example UWord; trying to get a toolbar working. And came across this code:

void UWord::FileBar(Bar& bar)
{
bar.Add("New", CtrlImg::new_doc(), THISBACK(New))
.Key(K_CTRL_N)
.Help("Open new window");


What is CtrlImg::new_doc()? I realize its an image but what do I need in order to use the built in images?


Re: CtrlImg::new_doc() [message #10786 is a reply to message #10785] Sat, 28 July 2007 23:45 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Nothing, just use them:)

See CtrlLib/Ctrl.iml.

Mirek
Re: CtrlImg::new_doc() [message #10788 is a reply to message #10786] Sun, 29 July 2007 00:10 Go to previous messageGo to next message
Mark999 is currently offline  Mark999
Messages: 6
Registered: July 2007
Promising Member
I keep getting the error

D:\MyApps\MTool\main.cpp(137) : error C2039: 'open_doc' : is not a member of 'Upp::CtrlImg'
D:\upp\uppsrc\Draw\iml_header.h(13) : see declaration of 'Upp::CtrlImg'


I've included the following similar to UWord.

#include <RichEdit/RichEdit.h>
#include <PdfDraw/PdfDraw.h>


using namespace Upp;

#define LAYOUTFILE <MTool/MTool.lay>
#include <CtrlCore/lay.h>

I have all the same packages as UWord.

What am I missing?
Re: CtrlImg::new_doc() [message #10790 is a reply to message #10788] Sun, 29 July 2007 00:20 Go to previous messageGo to next message
fudadmin is currently offline  fudadmin
Messages: 1321
Registered: November 2005
Location: Kaunas, Lithuania
Ultimate Contributor
Administrator
Just a guess. Is CtrlLib package added to any of your packages?
Re: CtrlImg::new_doc() [message #10791 is a reply to message #10790] Sun, 29 July 2007 00:49 Go to previous messageGo to next message
Mark999 is currently offline  Mark999
Messages: 6
Registered: July 2007
Promising Member
Embarassed
Guess why I'm getting errors with CtrlImg::open_doc()? It doesn't exist. Laughing

ok time for a break.
Re: CtrlImg::new_doc() [message #10792 is a reply to message #10791] Sun, 29 July 2007 00:54 Go to previous messageGo to next message
fudadmin is currently offline  fudadmin
Messages: 1321
Registered: November 2005
Location: Kaunas, Lithuania
Ultimate Contributor
Administrator
Mark999 wrote on Sat, 28 July 2007 23:49

Embarassed
Guess why I'm getting errors with CtrlImg::open_doc()? It doesn't exist. Laughing

ok time for a break.


then read your topic name and my signature... Smile
Re: CtrlImg::new_doc() [message #10858 is a reply to message #10788] Wed, 01 August 2007 18:08 Go to previous message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
There is no CtrlLib::open_doc().

I guess you wanted CtrlLib::open().

(Note: CtrlLib::new() is not possible because "new" is C++ keyword - that is why there is "_doc" appended Smile )

Mirek
Previous Topic: Toolbar and gray color in layout
Next Topic: General Menu Construction
Goto Forum:
  


Current Time: Fri Mar 29 12:35:10 CET 2024

Total time taken to generate the page: 0.01369 seconds