mirror of
https://review.haiku-os.org/haiku
synced 2025-01-20 21:41:28 +01:00
a691828008
(and fixed newline at the end of the file). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1726 a95241bf-73f2-0310-859d-f6bbb57e9c96
56 lines
1.3 KiB
C++
56 lines
1.3 KiB
C++
////////////////////////////////////////////////////////////////////////////////
|
|
//
|
|
// File: StringItem.h
|
|
//
|
|
// Description:
|
|
//
|
|
// Copyright 2001, Ulrich Wimboeck
|
|
//
|
|
////////////////////////////////////////////////////////////////////////////////
|
|
|
|
#ifndef _STRING_ITEM_H
|
|
#define _STRING_ITEM_H
|
|
|
|
#include <ListItem.h>
|
|
|
|
|
|
#ifdef USE_OPENBEOS_NAMESPACE
|
|
namespace OpenBeOS
|
|
{
|
|
#endif
|
|
|
|
/*----------------------------------------------------------------*/
|
|
/*----- BStringItem class ----------------------------------------*/
|
|
|
|
class BStringItem : public BListItem
|
|
{
|
|
public:
|
|
BStringItem(const char *text, uint32 outlineLevel = 0, bool expanded = true);
|
|
BStringItem(BMessage *data);
|
|
virtual ~BStringItem();
|
|
|
|
static BArchivable *Instantiate(BMessage *data);
|
|
virtual status_t Archive(BMessage *data, bool deep = true) const;
|
|
|
|
virtual void DrawItem(BView *owner, BRect frame, bool complete = false);
|
|
virtual void SetText(const char *text);
|
|
const char *Text() const;
|
|
|
|
virtual void Update(BView *owner, const BFont *font);
|
|
|
|
virtual status_t Perform(perform_code code, void *arg);
|
|
|
|
private:
|
|
BStringItem(const BStringItem &);
|
|
BStringItem& operator=(const BStringItem &);
|
|
|
|
char *fText;
|
|
float fBaselineOffset;
|
|
};
|
|
|
|
#ifdef USE_OPENBEOS_NAMESPACE
|
|
}
|
|
#endif
|
|
|
|
#endif /* _STRING_ITEM_H */
|