1998-07-29 22:54:36 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
|
|
|
*
|
|
|
|
* The contents of this file are subject to the Netscape Public License
|
|
|
|
* Version 1.0 (the "NPL"); you may not use this file except in
|
|
|
|
* compliance with the NPL. You may obtain a copy of the NPL at
|
|
|
|
* http://www.mozilla.org/NPL/
|
|
|
|
*
|
|
|
|
* Software distributed under the NPL is distributed on an "AS IS" basis,
|
|
|
|
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
|
|
|
|
* for the specific language governing rights and limitations under the
|
|
|
|
* NPL.
|
|
|
|
*
|
|
|
|
* The Initial Developer of this code under the NPL is Netscape
|
|
|
|
* Communications Corporation. Portions created by Netscape are
|
|
|
|
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
|
|
|
|
* Reserved.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __nsILookAndFeel
|
|
|
|
#define __nsILookAndFeel
|
|
|
|
#include "nsISupports.h"
|
|
|
|
#include "nsColor.h"
|
|
|
|
|
|
|
|
// {21B51DE1-21A3-11d2-B6E0-00805F8A2676}
|
|
|
|
#define NS_ILOOKANDFEEL_IID \
|
|
|
|
{ 0x21b51de1, 0x21a3, 0x11d2, \
|
|
|
|
{ 0xb6, 0xe0, 0x0, 0x80, 0x5f, 0x8a, 0x26, 0x76 } }
|
|
|
|
|
|
|
|
class nsILookAndFeel: public nsISupports {
|
|
|
|
public:
|
|
|
|
typedef enum {
|
1998-09-02 00:54:39 +04:00
|
|
|
eColor_WindowBackground,
|
|
|
|
eColor_WindowForeground,
|
|
|
|
eColor_WidgetBackground,
|
|
|
|
eColor_WidgetForeground,
|
|
|
|
eColor_WidgetSelectBackground,
|
|
|
|
eColor_WidgetSelectForeground,
|
|
|
|
eColor_Widget3DHighlight,
|
|
|
|
eColor_Widget3DShadow,
|
|
|
|
eColor_TextBackground,
|
|
|
|
eColor_TextForeground,
|
|
|
|
eColor_TextSelectBackground,
|
|
|
|
eColor_TextSelectForeground
|
1998-07-29 22:54:36 +04:00
|
|
|
} nsColorID;
|
|
|
|
|
|
|
|
typedef enum {
|
1998-09-02 00:54:39 +04:00
|
|
|
eMetric_WindowTitleHeight,
|
|
|
|
eMetric_WindowBorderWidth,
|
|
|
|
eMetric_WindowBorderHeight,
|
|
|
|
eMetric_Widget3DBorder,
|
1998-12-21 19:53:49 +03:00
|
|
|
eMetric_TextFieldHeight,
|
|
|
|
eMetric_TextVerticalInsidePadding, // needed only because of GTK
|
|
|
|
eMetric_TextShouldUseVerticalInsidePadding, // needed only because of GTK
|
|
|
|
eMetric_TextHorizontalInsideMinimumPadding,
|
|
|
|
eMetric_TextShouldUseHorizontalInsideMinimumPadding, // needed only because of GTK
|
|
|
|
eMetric_ButtonHorizontalInsidePaddingNavQuirks,
|
|
|
|
eMetric_ButtonHorizontalInsidePaddingOffsetNavQuirks,
|
|
|
|
|
|
|
|
eMetric_ListShouldUseHorizontalInsideMinimumPadding, // needed only because of GTK
|
|
|
|
eMetric_ListHorizontalInsideMinimumPadding,
|
|
|
|
|
|
|
|
eMetric_ListShouldUseVerticalInsidePadding, // needed only because of GTK
|
|
|
|
eMetric_ListVerticalInsidePadding // needed only because of GTK
|
1998-07-29 22:54:36 +04:00
|
|
|
} nsMetricID;
|
|
|
|
|
1998-12-21 19:53:49 +03:00
|
|
|
typedef enum {
|
|
|
|
eMetricFloat_TextFieldVerticalInsidePadding,
|
|
|
|
eMetricFloat_TextFieldHorizontalInsidePadding,
|
|
|
|
eMetricFloat_TextAreaVerticalInsidePadding,
|
|
|
|
eMetricFloat_TextAreaHorizontalInsidePadding,
|
|
|
|
eMetricFloat_ListVerticalInsidePadding,
|
|
|
|
eMetricFloat_ListHorizontalInsidePadding,
|
|
|
|
eMetricFloat_ButtonVerticalInsidePadding,
|
|
|
|
eMetricFloat_ButtonHorizontalInsidePadding
|
|
|
|
} nsMetricFloatID;
|
|
|
|
|
1998-09-02 00:54:39 +04:00
|
|
|
NS_IMETHOD GetColor(const nsColorID aID, nscolor &aColor) = 0;
|
|
|
|
NS_IMETHOD GetMetric(const nsMetricID aID, PRInt32 & aMetric) = 0;
|
1998-12-21 19:53:49 +03:00
|
|
|
NS_IMETHOD GetMetric(const nsMetricFloatID aID, float & aMetric) = 0;
|
1998-07-29 22:54:36 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
#define nsLAF nsILookAndFeel
|
|
|
|
|
|
|
|
#endif /* __nsILookAndFeel */
|