/**
 *
 * $Header: /cvsroot/lesstif/lesstif/lib/Xm-2.0/CSText.c,v 1.8 2001/04/02 19:05:43 amai Exp $
 *
 * Copyright (C) 1997 Free Software Foundation, Inc.
 * Copyright (C) 1997-2001 LessTif Development Team
 *
 * This file is part of the GNU LessTif Library.
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Library General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Library General Public
 * License along with this library; if not, write to the Free
 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 *
 **/


#include <LTconfig.h>

#include <Xm/XmP.h>
#include <Xm/CSTextP.h>

#include <XmI/DebugUtil.h>


/*
  MODULE: CSText.c
  DESCRIPTION:
  This is just a stub!
  END:
*/

/* declarations for dummies */
static void class_initialize(void);
static void class_part_initialize(WidgetClass w_class);
static void initialize(Widget request, Widget new_w,
		       ArgList args, Cardinal *num_args);
static void initialize_prehook(Widget request, Widget new_w,
			       ArgList args, Cardinal *num_args);
static void initialize_posthook(Widget request, Widget new_w,
				ArgList args, Cardinal *num_args);
static void destroy(Widget w);


/* Try to fake enough to get apps link ...
   -> the stuff below is just a bit cosmetics beyond -
      not meaningful data
 */

static XmBaseClassExtRec _XmCSTextCoreClassExtRec = {
    /* next_extension            */ NULL,
    /* record_type               */ NULLQUARK,
    /* version                   */ XmBaseClassExtVersion,
    /* size                      */ sizeof(XmBaseClassExtRec),
    /* initialize_prehook        */ initialize_prehook,
    /* set_values_prehook        */ XmInheritSetValuesPrehook,
    /* initialize_posthook       */ initialize_posthook,
    /* set_values_posthook       */ XmInheritSetValuesPosthook,
    /* secondary_object_class    */ XmInheritClass,
    /* secondary_object_create   */ XmInheritSecObjectCreate,
    /* get_secondary_resources   */ XmInheritGetSecResData,
    /* fast_subclass             */ { 0 },
    /* get_values_prehook        */ XmInheritGetValuesPrehook,
    /* get_values_posthook       */ XmInheritGetValuesPosthook,
    /* class_part_init_prehook   */ NULL,
    /* class_part_init_posthook  */ NULL,
    /* ext_resources             */ NULL,
    /* compiled_ext_resources    */ NULL,
    /* num_ext_resources         */ 0,
    /* use_sub_resources         */ False,
    /* widget_navigable          */ XmInheritWidgetNavigable,
    /* focus_change              */ XmInheritFocusChange,
    /* wrapper_data              */ NULL
};

static XmPrimitiveClassExtRec _XmCSTextPrimClassExtRec = {
    /* next_extension      */ NULL,
    /* record_type         */ NULLQUARK,
    /* version             */ XmPrimitiveClassExtVersion,
    /* record_size         */ sizeof(XmPrimitiveClassExtRec),
    /* widget_baseline     */ XmInheritBaselineProc,
    /* widget_display_rect */ XmInheritDisplayRectProc,
    /* widget_margins      */ NULL
};

XmCSTextClassRec xmCSTextClassRec  = {
    /* Core class part */
    {
	/* superclass            */ (WidgetClass) &xmPrimitiveClassRec,
	/* class_name            */ "XmCSText",
	/* widget_size           */ sizeof(XmCSTextRec),
	/* class_initialize      */ class_initialize,
	/* class_part_initialize */ class_part_initialize,
	/* class_inited          */ False,
	/* initialize            */ initialize,
	/* initialize_hook       */ NULL,
	/* realize               */ XtInheritRealize,
	/* actions               */ NULL,
	/* num_actions           */ 0,
	/* resources             */ NULL,
	/* num_resources         */ 0,
	/* xrm_class             */ NULLQUARK,
	/* compress_motion       */ True,
	/* compress_exposure     */ XtExposeCompressMaximal,
	/* compress_enterleave   */ True,
	/* visible_interest      */ False,
	/* destroy               */ destroy,
	/* resize                */ NULL,
	/* expose                */ NULL,
	/* set_values            */ NULL,
	/* set_values_hook       */ NULL,
	/* set_values_almost     */ XtInheritSetValuesAlmost,
	/* get_values_hook       */ NULL,
	/* accept_focus          */ NULL,
	/* version               */ XtVersionDontCheck,
	/* callback offsets      */ NULL,
	/* tm_table              */ NULL,
	/* query_geometry        */ XtInheritQueryGeometry,
	/* display_accelerator   */ NULL,
	/* extension             */ (XtPointer)&_XmCSTextCoreClassExtRec
    },
    /* Primitive Class part */
    {
	/* border_highlight      */ XmInheritBorderHighlight, /* FIX ME */
	/* border_unhighlight    */ XmInheritBorderUnhighlight, /* FIX ME */
	/* translations          */ XtInheritTranslations,
	/* arm_and_activate_proc */ NULL,
	/* synthetic resources   */ NULL,
	/* num syn res           */ 0,
	/* extension             */ (XtPointer)&_XmCSTextPrimClassExtRec
    },
    /* CSText Class part */
   {
    NULL
   }
};

WidgetClass xmCSTextWidgetClass = (WidgetClass)&xmCSTextClassRec;


static void class_initialize(void) {
    _XmWarning(NULL, "class_initialize(): XmCSText is not yet implemented!");
}


static void class_part_initialize(WidgetClass w_class) {
    _XmWarning(NULL, "class_part_initialize(): XmCSText is not yet implemented!");
}


static void initialize(Widget request, Widget new_w,
		       ArgList args, Cardinal *num_args) {
    _XmWarning(NULL, "initialize(): XmCSText is not yet implemented!");
}


static void initialize_prehook(Widget request, Widget new_w,
			       ArgList args, Cardinal *num_args) {
    _XmWarning(NULL, "initialize_prehook(): XmCSText is not yet implemented!");
}

			       
static void initialize_posthook(Widget request, Widget new_w,
				ArgList args, Cardinal *num_args) {
    _XmWarning(NULL, "initialize_posthooke(): XmCSText is not yet implemented!");
}


static void destroy(Widget w) {
    _XmWarning(NULL, "destroy(): XmCSText is not yet implemented!");
}


/* ************************ Public Interfaces *********************** */

extern Widget 
XmCreateCSText(Widget parent, String name, ArgList arglist, Cardinal argcount)
{
   /* FIXTHIS: Needs to be implemented */
    _XmWarning(NULL, "XmCreateCSText(): not yet implemented!");
   return NULL;
}


extern Widget 
XmCreateScrolledCSText(Widget parent, 
                       String name, 
                       ArgList arglist, 
                       Cardinal argcount)
{
   /* FIXTHIS: Needs to be implemented */
  _XmWarning(NULL, "XmCreateScrolledCSText(): not yet implemented!");
   return NULL;
}


extern XmString
XmCSTextGetString(Widget widget) {

  _XmWarning(NULL, "XmCSTextGetString(): not yet implemented!");
  return NULL;
}


extern void
XmCSTextSetString(Widget w, XmString value) {

  _XmWarning(NULL, "XmCSTextSetString(): not yet implemented!");
}


extern void 
XmCSTextReplace(Widget w,
                     XmTextPosition from_pos,
                     XmTextPosition to_pos,
                     XmString value) {

  _XmWarning(NULL, "XmCSTextReplace(): not yet implemented!");
}


extern void
XmCSTextRead(Widget w,
                  XmTextPosition frompos,
                  XmTextPosition topos,
                  XmString *value) {

  _XmWarning(NULL, "XmCSTextRead(): not yet implemented!");
}


extern void
XmCSTextInsert(Widget w,
                    XmTextPosition position,
                    XmString value) {

  _XmWarning(NULL, "XmCSTextInsert(): not yet implemented!");
}


extern Boolean
XmCSTextGetEditable(Widget w) {

  _XmWarning(NULL, "XmCSTextGetEditable(): not yet implemented!");
  return False;
}


extern void
XmCSTextSetEditable(Widget w,
#if NeedWidePrototypes
                         int editable)
#else
                         Boolean editable)
#endif
 {

  _XmWarning(NULL, "XmCSTextSetEditable(): not yet implemented!");
}

 
extern int
XmCSTextGetMaxLength(Widget w) {

  _XmWarning(NULL, "XmCSTextGetMaxLength(): not yet implemented!");
  return 0;
}


extern void
XmCSTextSetMaxLength(Widget w, int max_length) {

  _XmWarning(NULL, "XmCSTextGetMaxLength(): not yet implemented!");
}


extern XmStringDirection
XmCSTextGetTextPath(Widget w) {

  _XmWarning(NULL, "XmCSTextGetTextPath(): not yet implemented!");
  return 0;
}


extern void
XmCSTextSetTextPath(Widget w, XmStringDirection path) {

  _XmWarning(NULL, "XmCSTextSetTextPath(): not yet implemented!");
}


extern XmString
XmCSTextGetSelection(Widget w) {

  _XmWarning(NULL, "XmCSTextGetSelection(): not yet implemented!");
  return NULL;
}


extern Boolean
XmCSTextGetSelectionPosition(Widget w, 
                                     XmTextPosition *left,
                                     XmTextPosition *right) {

  _XmWarning(NULL, "XmCSTextGetSelectionPosition(): not yet implemented!");
  return False;
}


extern void
XmCSTextSetSelection(Widget w,
                          XmTextPosition first,
                          XmTextPosition last,
                          Time time) {

  _XmWarning(NULL, "XmCSTextSetSelection(): not yet implemented!");
}


extern void
XmCSTextClearSelection(Widget w, Time time) {

  _XmWarning(NULL, "XmCSTextClearSelection(): not yet implemented!");
}


extern Boolean
XmCSTextCopy(Widget w, Time time) {

  _XmWarning(NULL, "XmCSTextCopy(): not yet implemented!");
  return False;
}


extern Boolean
XmCSTextCut(Widget w, Time time) {

  _XmWarning(NULL, "XmCSTextCut(): not yet implemented!");
  return False;
}


extern Boolean
XmCSTextPaste(Widget w) {

  _XmWarning(NULL, "XmCSTextPaste(): not yet implemented!");
  return False;
}


extern Boolean
XmCSTextRemove(Widget w) {

  _XmWarning(NULL, "XmCSTextRemove(): not yet implemented!");
  return False;
}


extern void
XmCSTextShowPosition(Widget w, XmTextPosition position) {

  _XmWarning(NULL, "XmCSTextShowPosition(): not yet implemented!");
}


extern void
XmCSTextScroll(Widget w, int lines) {

  _XmWarning(NULL, "XmCSTextScroll(): not yet implemented!");
}


extern void
XmCSTextDisableRedisplay(Widget w) {

  _XmWarning(NULL, "XmCSTextDisableRedisplay(): not yet implemented!");
}


extern void
XmCSTextEnableRedisplay(Widget w) {

  _XmWarning(NULL, "XmCSTextEnableRedisplay(): not yet implemented!");
}


extern void
XmCSTextMarkRedraw(Widget w,
                        XmTextPosition  left,
                        XmTextPosition  right) {

  _XmWarning(NULL, "XmCSTextMarkRedraw(): not yet implemented!");
}


extern void
XmCSTextSetHighlight(Widget w,
                          XmTextPosition left,
                          XmTextPosition right,
                          XmHighlightMode mode) {

  _XmWarning(NULL, "XmCSTextSetHighlight(): not yet implemented!");
}


extern XmTextPosition
XmCSTextGetTopCharacter(Widget w) {

  _XmWarning(NULL, "XmCSTextGetTopCharacter(): not yet implemented!");
  return 0;
}


extern void
XmCSTextSetTopCharacter(Widget w, XmTextPosition top_position) {

  _XmWarning(NULL, "XmCSTextSetTopCharacter(): not yet implemented!");
}


extern XmTextPosition
XmCSTextGetLastPosition(Widget w) {

  _XmWarning(NULL, "XmCSTextGetLastPosition(): not yet implemented!");
  return 0;
}


extern XmTextPosition
XmCSTextGetCursorPosition(Widget w) {

  _XmWarning(NULL, "XmCSTextGetCursorPosition(): not yet implemented!");
  return 0;
}


extern XmTextPosition
XmCSTextGetInsertionPosition(Widget w) {

  _XmWarning(NULL, "XmCSTextGetInsertionPosition(): not yet implemented!");
  return 0;
}


extern void
XmCSTextSetInsertionPosition(Widget w, XmTextPosition position) {

  _XmWarning(NULL, "XmCSTextSetInsertionPosition(): not yet implemented!");
}


extern XmTextPosition
XmCSTextXYToPos(Widget w,
#if NeedWidePrototypes
                               int x,
                               int y)
#else
                               Position x,
                               Position y)
#endif
 {

  _XmWarning(NULL, "XmCSTextXYToPos(): not yet implemented!");
  return 0;
}


extern Boolean
XmCSTextPosToXY(Widget w,
                        XmTextPosition position,
                        Position *x,
                        Position *y) {

  _XmWarning(NULL, "XmCSTextPosToXY(): not yet implemented!");
  return False;
}


extern XmString
XmCSTextGetStringWrapped(Widget w,
                        XmTextPosition start,
                        XmTextPosition end) {

  _XmWarning(NULL, "XmCSTextGetStringWrapped(): not yet implemented!");
  return NULL;
}


extern Boolean
XmCSTextFindString(Widget w,
                           XmTextPosition start,
                           String string,
                           XmTextDirection direction,
                           XmTextPosition *position ) {

  _XmWarning(NULL, "XmCSTextFindString(): not yet implemented!");
  return False;
}


extern Boolean
XmCSTextFindStringWcs(Widget w,
                              XmTextPosition start,
                              wchar_t *wcstring,
                              XmTextDirection direction,
                              XmTextPosition *position ) {

  _XmWarning(NULL, "XmCSTextFindStringWcs(): not yet implemented!");
  return False;
}


extern int
XmCSTextGetSubstring(Widget w,
                         XmTextPosition start,
                         int num_chars,
                         int buffer_size,
                         String buffer) {

  _XmWarning(NULL, "XmCSTextGetSubstring(): not yet implemented!");
  return 0;
}


extern int
XmCSTextGetSubstringWcs(Widget w,
                            XmTextPosition start,
                            int num_chars,
                            int buffer_size,
                            wchar_t *buffer) {

  _XmWarning(NULL, "XmCSTextGetSubstringWcs(): not yet implemented!");
  return 0;
}


extern void
XmCSTextSetAddMode(Widget w,
#if NeedWidePrototypes
                        int state)
#else
                        Boolean state)
#endif
 {

  _XmWarning(NULL, "XmCSTextSetAddMode(): not yet implemented!");
}


extern void
XmCSTextSetSource(Widget w,
                       XmCSTextSource source,
                       XmTextPosition top_character,
                       XmTextPosition cursor_position) {

  _XmWarning(NULL, "XmCSTextSetSource(): not yet implemented!");
}


extern XmCSTextSource
XmCSTextGetSource(Widget w) {

  _XmWarning(NULL, "XmCSTextGetSource(): not yet implemented!");
  return NULL;
}


extern int
XmCSTextGetBaseline(Widget w) {

  _XmWarning(NULL, "XmCSTextGetBaseline(): not yet implemented!");
  return 0;
}


extern Boolean
XmCSTextPasteLink(Widget w) {

  _XmWarning(NULL, "XmCSTextPasteLink(): not yet implemented!");
  return False;
}


extern Boolean
XmCSTextCopyLink(Widget w, Time time) {

  _XmWarning(NULL, "XmCSTextCopyLink(): not yet implemented!");
  return False;
}
