rpms/reciteword/F-7 reciteword-0.8.3-fix.patch, NONE, 1.1 reciteword.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Hu Zheng (zhu) fedora-extras-commits at redhat.com
Wed Jun 20 07:16:34 UTC 2007


Author: zhu

Update of /cvs/pkgs/rpms/reciteword/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv25272/F-7

Modified Files:
	.cvsignore sources 
Added Files:
	reciteword-0.8.3-fix.patch reciteword.spec 
Log Message:


reciteword-0.8.3-fix.patch:

--- NEW FILE reciteword-0.8.3-fix.patch ---
diff -r -u reciteword-0.8.3/po/zh_CN.po reciteword-0.8.3.fix/po/zh_CN.po
--- reciteword-0.8.3/po/zh_CN.po	2006-03-26 16:40:42.000000000 +0800
+++ reciteword-0.8.3.fix/po/zh_CN.po	2007-06-07 14:47:20.000000000 +0800
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: reciteword-0.6.0\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2006-03-26 16:37+0800\n"
+"POT-Creation-Date: 2007-05-01 10:23+0800\n"
 "PO-Revision-Date: 2002-09-22 15:14+0800\n"
 "Last-Translator: huzheng <huzheng_001 at 163.com>\n"
 "Language-Team: zh_CN <i18n-translation at lists.linux.net.cn>\n"
@@ -57,7 +57,7 @@
 
 #: src/collectword.cpp:128
 msgid "Collect my hard words"
-msgstr ""
+msgstr "收集我的疑难单词"
 
 #: src/dict.cpp:152
 msgid "Dict"
@@ -178,7 +178,7 @@
 msgid "Sound"
 msgstr "声音"
 
-#: src/option.cpp:77 src/reciteword.cpp:1384
+#: src/option.cpp:77 src/reciteword.cpp:1388
 msgid "ReciteWord"
 msgstr "背单词"
 
diff -r -u reciteword-0.8.3/reciteword.desktop reciteword-0.8.3.fix/reciteword.desktop
--- reciteword-0.8.3/reciteword.desktop	2003-05-03 22:26:13.000000000 +0800
+++ reciteword-0.8.3.fix/reciteword.desktop	2007-06-07 14:47:41.000000000 +0800
@@ -1,11 +1,12 @@
 [Desktop Entry]
+Encoding=UTF-8
+Type=Application
 Name=Recite Word
 Name[zh_CN]=背单词
 Comment=Recite word easily
 Comment[zh_CN]=黑客背单词
 Exec=reciteword
-Terminal=0
-Type=Application
+Terminal=false
 Icon=reciteword.png
 StartupNotify=true
-Categories=Application;Office;
+Categories=Education;Languages;
diff -r -u reciteword-0.8.3/rwdict.desktop reciteword-0.8.3.fix/rwdict.desktop
--- reciteword-0.8.3/rwdict.desktop	2003-05-03 22:28:22.000000000 +0800
+++ reciteword-0.8.3.fix/rwdict.desktop	2007-06-07 14:47:48.000000000 +0800
@@ -1,11 +1,12 @@
 [Desktop Entry]
+Encoding=UTF-8
+Type=Application
 Name=RWDict
 Name[zh_CN]=词典
 Comment=ReciteWord's Dict
 Comment[zh_CN]=黑客背单词的词典
 Exec=reciteword -d
-Terminal=0
-Type=Application
+Terminal=false
 Icon=rwdict.png
 StartupNotify=true
-Categories=Application;Office;
+Categories=Utility;Dictionary;
diff -r -u reciteword-0.8.3/src/choosebook.cpp reciteword-0.8.3.fix/src/choosebook.cpp
--- reciteword-0.8.3/src/choosebook.cpp	2006-03-26 16:27:25.000000000 +0800
+++ reciteword-0.8.3.fix/src/choosebook.cpp	2007-06-15 13:05:32.000000000 +0800
@@ -352,7 +352,7 @@
 		{
 			GtkTreeIter child_iter;
 			gtk_tree_store_append (model, &child_iter,iter);
-			sprintf(dirnamefile, "%s/.dirname", fullname);
+			sprintf(dirnamefile, "%s/dirname", fullname);
 			if (g_file_test(dirnamefile, G_FILE_TEST_EXISTS)) {
 				if (g_file_get_contents(dirnamefile, &tmp1, NULL, NULL))
 					g_strstrip(tmp1);
diff -r -u reciteword-0.8.3/src/reciteword.cpp reciteword-0.8.3.fix/src/reciteword.cpp
--- reciteword-0.8.3/src/reciteword.cpp	2006-03-26 16:32:27.000000000 +0800
+++ reciteword-0.8.3.fix/src/reciteword.cpp	2007-06-07 14:50:07.000000000 +0800
@@ -1375,7 +1375,11 @@
 	window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
 //	gtk_widget_pop_visual ();
 //	gtk_widget_pop_colormap ();
+#ifdef G_OS_WIN32
+	gtk_widget_set_events(window,GDK_SCROLL_MASK | GDK_BUTTON_PRESS_MASK);
+#else
 	gtk_widget_set_events(window,GDK_SCROLL_MASK);
+#endif
 	gtk_window_set_decorated (GTK_WINDOW (window), FALSE);
 	gtk_widget_set_app_paintable(window,TRUE);
 	gtk_window_set_resizable(GTK_WINDOW(window),FALSE);
diff -r -u reciteword-0.8.3/src/revise.cpp reciteword-0.8.3.fix/src/revise.cpp
--- reciteword-0.8.3/src/revise.cpp	2006-03-26 16:33:14.000000000 +0800
+++ reciteword-0.8.3.fix/src/revise.cpp	2007-06-07 14:49:18.000000000 +0800
@@ -588,7 +588,6 @@
 	gdk_colormap_alloc_color (parent->cmap, &(parent->color), FALSE,
 				  TRUE);
 	//gdk_color_change(parent->cmap,&(parent->color));
-	parent->draw (3);
 	if (parent->color.red == 0x0000)
 	{
 		parent->refresh();
@@ -610,8 +609,10 @@
 		parent->disappear_timer = 0;
 		return FALSE;
 	}
-	else
+	else {
+		parent->draw (3);
 		return TRUE;
+	}
 }
 
 tViewer::tViewer ()
@@ -676,13 +677,17 @@
 	str2 = str_m;
 	if (layout_w)
 		pango_layout_set_text(layout_w,str1,-1);
-	else
-	{
+	else {
 		layout_w=gtk_widget_create_pango_layout (text_area, str1);
 		pango_layout_set_font_description(layout_w,Skin->reciteword.b_font);
 	}
-	if (layout_m)
-		pango_layout_set_text(layout_m,str2,-1);
+	if (layout_m) {
+		if (str2) {
+			pango_layout_set_text(layout_m,str2,-1);
+		} else {
+			pango_layout_set_text(layout_m,"",-1);
+		}
+	}
 	else
 		layout_m=gtk_widget_create_pango_layout (text_area, str2);
 	if (g_pReciteWord->revise_skim->readword_ckbutton.status)
diff -r -u reciteword-0.8.3/src/tools/getBdcSound.c reciteword-0.8.3.fix/src/tools/getBdcSound.c
--- reciteword-0.8.3/src/tools/getBdcSound.c	2003-03-06 19:03:19.000000000 +0800
+++ reciteword-0.8.3.fix/src/tools/getBdcSound.c	2007-06-07 14:49:48.000000000 +0800
@@ -16,8 +16,8 @@
 	static unsigned char c2[21],b1[21];
 	int i,j,len;	
 	
-	strcpy(b1,str);
-	len = strlen(b1);
+	strcpy((char *)b1,(char *)str);
+	len = strlen((char *)b1);
 
 	if (len==1)
     {
@@ -262,7 +262,7 @@
         wav[57]= (((wavweight) & 0xff000000)>>24);		
 		fseek(wordwavFile,wavbegin,0);
 		fread(&wav[0x3a], wavweight,1,wordwavFile);
-		str = get_word_str(idxbuf);
+		str = (char *)get_word_str(idxbuf);
 		dirchar = tolower(str[0]);	
 		sprintf(wavfilename,"BdcSound/%c/%s.wav",dirchar,str);
 		if (!stat(wavfilename, &st))
diff -r -u reciteword-0.8.3/src/widget.cpp reciteword-0.8.3.fix/src/widget.cpp
--- reciteword-0.8.3/src/widget.cpp	2005-10-06 15:32:10.000000000 +0800
+++ reciteword-0.8.3.fix/src/widget.cpp	2007-06-07 14:52:21.000000000 +0800
@@ -817,7 +817,7 @@
 	default:
 		return_val = TRUE;
 		if ((length < parent->max_length) && (event->keyval >= 0x20)
-		    && (event->keyval <= 0xFF))
+		    && (event->keyval <= 0x7E))
 		{
 			gchar key;
 			key = event->keyval;


--- NEW FILE reciteword.spec ---
Name: reciteword
Summary: Recite Word Easily
Version: 0.8.3
Release: 2%{?dist}
Group: Applications/Productivity
License: GPL
URL: http://reciteword.cosoft.org.cn
Source0: http://reciteword.cosoft.org.cn/reciteword/download/%{name}-0.8.3.tar.bz2
Source1: http://reciteword.cosoft.org.cn/reciteword/download/%{name}-books-0.8.3.tar.bz2
Source2: http://reciteword.cosoft.org.cn/reciteword/download/%{name}-dicts-0.8.2.tar.bz2
Patch0: reciteword-0.8.3-fix.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

Requires: gtk2 >= 2.2
Requires: esound >= 0.2.28
BuildRequires: gtk2-devel >= 2.2, esound-devel >= 0.2.28

%description
ReciteWord is an education software to help people to study English,
recite words.

%description -l zh_CN
黑客背单词。

%prep
%setup -q
%setup -q -n %{name}-%{version} -D -T -a 1
find books -name .dirname -exec rename .dirname dirname {} \;
%setup -q -n %{name}-%{version} -D -T -a 2
%patch0 -p1 -b .fix

%build
%configure
make

%install
rm -rf $RPM_BUILD_ROOT
make DESTDIR=$RPM_BUILD_ROOT install
cp -rf books $RPM_BUILD_ROOT%{_datadir}/%{name}/
cp -rf dicts $RPM_BUILD_ROOT%{_datadir}/%{name}/

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-, root, root, -)

%{_bindir}/reciteword
%{_datadir}/*


%changelog
* Thu Jun 15 2007 Hu Zheng <zhu at redhat.com> - 0.8.3-2
- Small fixes according to Parag AN's suggestion.

* Thu Jun 7 2007 Hu Zheng <zhu at redhat.com> - 0.8.3-1
- Initial build for Fedora


Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/reciteword/F-7/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	20 Jun 2007 04:45:01 -0000	1.1
+++ .cvsignore	20 Jun 2007 07:15:59 -0000	1.2
@@ -0,0 +1,3 @@
+reciteword-0.8.3.tar.bz2
+reciteword-books-0.8.3.tar.bz2
+reciteword-dicts-0.8.2.tar.bz2


Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/reciteword/F-7/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	20 Jun 2007 04:45:01 -0000	1.1
+++ sources	20 Jun 2007 07:15:59 -0000	1.2
@@ -0,0 +1,3 @@
+5c7b106787f956ace8059f91bcec1836  reciteword-0.8.3.tar.bz2
+9fb497b9f1c048aaf1ff16106a3e3ead  reciteword-books-0.8.3.tar.bz2
+f41d9dd162c4360924cfedb5cce3e5af  reciteword-dicts-0.8.2.tar.bz2




More information about the fedora-extras-commits mailing list